Daily Archives

Articles indexed Thursday December 30 2010

Page 20/34 | < Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >

  • Rails 3 routes and using GET to create clean URLs?

    - by Hard-Boiled Wonderland
    I am a little confused with the routes in Rails 3 as I am just starting to learn the language. I have a form generated here: <%= form_tag towns_path, :method => "get" do %> <%= label_tag :name, "Search for:" %> <%= text_field_tag :name, params[:name] %> <%= submit_tag "Search" %> <% end %> Then in my routes: get "towns/autocomplete_town_name" get "home/autocomplete_town_name" match 'towns' => 'towns#index' match 'towns/:name' => 'towns#index' resources :towns, :module => "town" resources :businesses, :module => "business" root :to => "home#index" So why when submitting the form do I get the URL: /towns?utf8=?&name=townname&commit=Search So the question is how do I make that url into a clean url like: /towns/townname Thanks, Andrew

    Read the article

  • Trying to parse out the $_POST key names that I don't want

    - by Adam
    $post_keys = array_keys($_POST); $special_keys = array(); for($i=0;$i<count($post_keys);$i++){ if(strpos($post_keys[$i], "special") !== false){ $special_keys[] = $post_keys[$i]; } } I have numerous post vars with naming conventions such as special0, special0_time, special0_duration, special1, special1_time etc.... What I want to do is to find out how many main groups there are, so special0, special1 etc... The code I currently have searches all key names that have "special" in it, thus retrieving more than I want.

    Read the article

  • Problem with Ajax [SYS.webforms.pagerequestmanagerserver exception]

    - by Homam
    I'm new in web development, I have a problem in a web application after deployment (it's not appeared in my development machine), The error in IE after enable the debug mode: SYS.webforms.pagerequestmanagerserver error exception has been thrown by the target of an invocation scriptresources.axd The error is shown when an Ajax ModalPopupExtender is opened. Inside the popup there's a user control and inside the user control there's a RadGrid from telerik contains a RadAsyncUpload in a GridTemplateColumn kindly ask me for any extra information Thanks in advance

    Read the article

  • Where to find good 3d articles for wpf?

    - by Ankit Rathod
    Hello, I am beginner in WPF. I am basically a Silverlight guy and as i know it doesn't support the full real 3d model of WPF. I am getting interested in learning 3D in WPF. I googled up for WPF and i get very old links which are 3 years old back when WPF was known as Avalon. They may not be of any use in V4.0. Can anybody refer me some links where i can learn WPF 3D from basics? Thanks in advance :)

    Read the article

  • Extend and Overload MS and Point Types

    - by dr d b karron
    Do I have make my own Point and Vector types to overload them ? Why does this not work ? namespace System . windows { public partial struct Point : IFormattable { public static Point operator * ( Point P , double D ) { Point Po = new Point ( ); return Po; } } } namespace SilverlightApplication36 { public partial class MainPage : UserControl { public static void ShrinkingRectangle ( WriteableBitmap wBM , int x1 , int y1 , int x2 , int y2 , Color C ) { wBM . DrawRectangle ( x1 , y1 , x2 , y2 , Colors . Red ); Point Center = Mean ( x1 , y1 , x2 , y2 ); wBM . SetPixel ( Center , Colors.Blue , 3 ); Point P1 = new Point ( x1 , y1 ); Point P2 = new Point ( x1 , y2 ); Point P3 = new Point ( x1 , y2 ); Point P4 = new Point ( x2 , y1 ); const int Steps = 10; for ( int i = 0 ; i < Steps ; i++ ) { double iF = (double)(i+1) / (double)Steps; double jF = ( 1.0 - iF ); Point P11 = **P1 * jF;** } }

    Read the article

  • Windows service (hosting WCF service) stops immediately on start up

    - by Thr33Dii
    My Question: I cannot navigate to the base address once the service is installed because the service won't remain running (stops immediately). Is there anything I need to do on the server or my machine to make the baseAddress valid? Background: I'm trying to learn how to use WCF services hosted in Windows Services. I have read several tutorials on how to accomplish this and it seems very straight forward. I've looked at this MSDN article and built it step-by-step. I can install the service on my machine and on a server, but when I start the service, it stops immediately. I then found this tutorial, which is essentially the same thing, but it contains some clients that consume the WCF service. I downloaded the source code, compiled, installed, but when I started the service, it stopped immediately. Searching SO, I found a possible solution that said to define the baseAddress when instantiating the ServiceHost, but that didnt help either. My serviceHost is defined as: serviceHost = new ServiceHost( typeof( CalculatorService ), new Uri( "http://localhost:8000/ServiceModelSamples/service" ) ); My service name, base address, and endpoint: <service name="Microsoft.ServiceModel.Samples.CalculatorService" behaviorConfiguration="CalculatorServiceBehavior"> <host> <baseAddresses> <add baseAddress="http://localhost:8000/ServiceModelSamples/service"/> </baseAddresses> </host> <endpoint address="" binding="wsHttpBinding" contract="Microsoft.ServiceModel.Samples.ICalculator"/> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/> </service> I've verified the namespaces are identical. It's just getting frustrating that the tutorials seem to assume that the Windows service will start as long as all the stated steps are followed. I'm missing something and it's probably right in front of me. Please help!

    Read the article

  • Validation control issue

    - by Mael
    Hello, I have a multiview that simulates a menu with different kind of options. Each view within the multiview control holds a bunch of controls (listbox, label, etc..) Everything worked just fine, until i wanted to implement Validation control(s). For example when i click on my menu viewA gets displayed with its controls. There i wish to implement a RequiredFieldValidator. But the problem is, if i click on a other menu option (which is in fact a other view in my multiview) then it gives the error message 'Please enter a message" which is the errorMessage of the first RequiredFieldValidator of the first menu option (first view). All my controls are named with a unique name, so there is no mixup amongst the ControlToValidate="" Offcourse this is not suitable, cause those menu choices are indepentant. And its not the intention i have to fill in everything, cause its a menu afterall, and not a form where i have to enter everything at once. How can i have a RequiredFieldValidator on my views that do not take each other in account? Some code on how my active view is handled protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { View activeView = (View)this.mvMultiview.FindControl(this.getViewFromRequest()); if (!(activeView == null)) { this.mvMultiview.SetActiveView(activeView); } } } Thanks.

    Read the article

  • BizTalk 2009 - Pipeline Component Wizard

    - by Stuart Brierley
    Recently I decided to try out the BizTalk Server Pipeline Component Wizard when creating a new pipeline component for BizTalk 2009. There are different versions of the wizard available, so be sure to download the appropriate version for the BizTalk environment that you are working with. Following the download and expansion of the zip file, you should be left with a Visual Studio solution.  Open this solution and build the project. Following this installation is straight foward - locate and run the built setup.exe file in the PipelineComponentWizard Setup project and click through the small number of installation screens. Once you have completed installation you will be ready to use the wizard in Visual Studio to create your BizTalk Pipeline Component. Start by creating a new project, selecting BizTalk Projects then BizTalk Server Pipeline Component.  You will then be presented with the splash screen. The next step is General Setup, where you will detail the classname, namespace, pipeline and component types, and the implementation language for your Pipeline Component. The options for pipeline type are Receive, Send or Any. Depending on the pipeline type chosen there are different options presented for the component type, matching those available within the BizTalk Pipelines themselves: Receive - Decoder, Disassembling Parser, Validate, Party Resolver, Any. Send -  Encoder, Assembling Serializer, Any. Any - Any. The options for implementation language are C# or VB.Net Next you must set up the UI settings - these are the settings that affect the appearance of the pipeline component within Visual Studio. You must detail the component name, version, description and icon.  Next is the definition of the variables that the pipeline component will use.  The values for these variables will be defined in Visual Studio when creating a pipeline. The options for each variable you require are: Designer Property - The name of the variable. Data Type - String, Boolean, Integer, Long, Short, Schema List, Schema With None Clicking finish now will complete the wizard stage of the creation of your pipeline component. Once the wizard has completed you will be left with a BizTalk Server Pipeline Component project containing a skeleton code file for you to complete.   Within this code file you will mainly be interested in the execute method, which is left mostly empty ready for you to implement your custom pipeline code:          #region IComponent members         /// <summary>         /// Implements IComponent.Execute method.         /// </summary>         /// <param name="pc">Pipeline context</param>         /// <param name="inmsg">Input message</param>         /// <returns>Original input message</returns>         /// <remarks>         /// IComponent.Execute method is used to initiate         /// the processing of the message in this pipeline component.         /// </remarks>         public Microsoft.BizTalk.Message.Interop.IBaseMessage Execute(Microsoft.BizTalk.Component.Interop.IPipelineContext pc, Microsoft.BizTalk.Message.Interop.IBaseMessage inmsg)         {             //             // TODO: implement component logic             //             // this way, it's a passthrough pipeline component             return inmsg;         }         #endregion Once you have implemented your custom code, build and compile your Custom Pipeline Component then add the compiled .dll to C:\Program Files\Microsoft BizTalk Server 2009\Pipeline Components . When creating a new pipeline, in Visual Studio reset the toolbox and the custom pipeline component should appear ready for you to use in your Biztalk Pipeline. Drop the pipeline component into the relevant pipeline stage and configure the component properties (the variables defined in the wizard). You can now deploy and use the pipeline as you would any other custom pipeline.

    Read the article

  • How to query a DHCP server to get the local DNS serves

    - by Dan Berlyoung
    I have a ClarkConnect (CentOS based) box running as my home router on a RR connection. I had the DNS servers set up to use Google's DNS server. I want to change them back to the local DNS servers but I can't find an obvious/easy way to get those address short of a)reconfiguring the router's network to DHCP them (would rather not interrupt everyone) or b)calling their T/S (kill me now!). Is there a command line tool/command I can use to query the DHCP server on the external NIC to see what DNS servers it would set me up with w/o munging my existing setup?

    Read the article

  • Active Server Pages error 'ASP 0126' classic asp pls help

    - by sagarmatha
    Hi friends, our company have a a old classic asp application, we have no choice but to host it. I just moved it to another server. It was perfectly running fine in old server but in this new server it's continuously giving this error. I am running windows 2003 server with IIS 6. Why I am geting this error ? please help. Active Server Pages error 'ASP 0126' Include file not found /application/unprocessed_application.asp, line 56 The include file '../../_fplclass/pdblib.inc' was not found.

    Read the article

  • Must I have Exchange to use Blackberry Enterprise Server Express?

    - by John Spaz
    In the past I've setup BES (not express) for a company that just wanted their users on the corporate network, they didn't care for email or any other enterprise feature, they just wanted to push a policy that the phones internet should be routed through the corporate network. I want to setup BES Express now for a customer that also just wants the phones on his network but wherever I look, it says that BES Express requires Exchange. Is there a way to install BES Express without Exchange and without a AD Domain? Basically what the customer wants to accomplish is to be able to filter and log the internet access on the phones.

    Read the article

  • ldap sync with outlook

    - by Dr Casper Black
    Hi, I have a task to research the possibilities of LDAP as a centralized Address Book. I have setup a openLDAP on debian 5.07. I managed to search the LDAP contacts from MS Outlook 2007 (with some drawbacks like Outlook cant recognize street and organization fields). My question is, is it possible ,& how, to sync data on LDAP server with applications that support LDAP? I could not find any data on this topic.

    Read the article

  • Writing directory: permission denied even though dir seems to be chmodded correctly

    - by Aron Rotteveel
    I am having some trouble creating files in directory on my Ubuntu machine: I added myself to the www-data group in order for me to easily edit stuff in my /var/www dir on my development machine. stat /var/www shows the following: File: ‘/var/www’ Size: 4096 Blocks: 8 IO Block: 4096 map Device: 808h/2056d Inode: 142853 Links: 3 Access: (0775/drwxrwxr-x) Uid: ( 33/www-data) Gid: ( 33/www-data) Access: 2010-12-30 16:03:18.563998000 +0100 Modify: 2010-12-30 16:02:52.663998000 +0100 Change: 2010-12-30 16:03:13.111998001 +0100 Still, it is impossible for me to create anything below /var/www (the only way for it to work is to chmod it to 777. What am I missing?

    Read the article

  • pfsense multi-site VPN VOIP deployment

    - by sysconfig
    have main office pfsense firewall configured like this: local networks WAN - internet LAN - local network VOIP - IP phones need to connect remote offices (multi-users) and single remote users (from home) use IPSEC or OpenVPN to build "permanent" automatically connecting tunnels from remote location to main location. in remote locations, network will look like this: WAN - internet LAN - local network multiple users VOIP - multiple IP phones in order for the IP phones to work they have to be able to "see" the VOIP network and the VOIP server back at the main office for single remote users ( like from home ) the setup will be similar but only one phone and one computer so questions: best way to tie networks together? IPSEC or OpenVPN can this be setup to automatically connect ? any issues/suggestions with that design/topology ? QoS or issues with running the VOIP traffic over a VPN throughput, quality etc.. obviously depends on remote locations connection to some degree

    Read the article

  • Is there an application that can automatically set Graphics Properties when docking?

    - by Ken Liu
    I have a dual display setup with my laptop (Dell, with integrated graphics, WinXP). The problem is that whenever I hook up the laptop to the monitor I have to go to Graphics Properties (Intel Graphics Media Driver for Mobile) and set the display resolution, window position, etc. Note that this screen is different than the built-in one you usually see in WinXP. 1) Is there an app that can save display settings properly so they will come back when I dock again? 2) Barring this, run a script or a macro to automatically set up the display the way I want it. 3) Or, can I write a .Net program that does this for me? Extra points if there is an Open source app that can do this.

    Read the article

  • How to associate localhost in Snow Leopard to a specific ip ?

    - by Patrick
    I've disabled the web server on Snow Leopard, and I'm using an emulated Ubuntu with Lighttpd web server. In order to access to the web pages I need to specify the ip of the emulated machine. However I now need to associated such ip with "localhost" in Leopard environment. When I type localhost in Leopard I actually want to visit the localhost on the Ubuntu machine. Do I need apache on leopard to make the forward or can I change network settings in Leopard or what ? thanks

    Read the article

  • Java Development in Linux

    - by Zac
    I'm a developer and am brand new to Linux (Ubuntu): I'm wondering what the "best practices dictate" for what FHS directories to install various tools to. Things I'll be installing: Eclipse & plugins GlassFish SVN ...etc. I see that /opt is for holding additional ("optional") software packages, but also see /usr as a place for utils and apps. In another post a user recommended I create an entire partition for /srv alone, and to do my staging there (I assume he meant that /srv is where GlassFish and other servers should go?). So basically: what FHS directories do Linux developers use for which type of tools? Thanks for any input here

    Read the article

  • network path not found error on creating schtasks

    - by user50273
    I am getting "ERROR: Network path was not found" when I try to create a scheduled task on my local machine. I am using this command at the command prompt: schtasks /tn taskname /tr taskpath /sc minute /mo 20 /sd 09/23/2010 /s \\%computername% /u username /p password When I give the above command without computername, username and password the task gets created perfectly fine. What am I doing wrong?? EDIT : I got it working by using the below command. I do not understand why it is working becuase I am using /ru and /rp which are remote user and remote password settings whereas I am executing the command on my local machine. And I had to give double quotes to computername. schtasks /tn taskname /tr taskpath /sc minute /mo 20 /sd 09/23/2010 /s "%computername%" /ru username /rp password

    Read the article

  • Emacs: Prevent TRAMP connection closing

    - by Josh
    I'm using emacs with TRAMP ( C-x C-f /ftp:[email protected]:/ ), and randomly, sometimes ten minutes, sometimes, ~12 seconds (no exaggerating) my connection will close (I think). I'll try to type, or list a dir, and it will say "Opening FTP connection to site.com...". Is there a way to tell it to just keep the connection open until I exit? Or is it the webserver killing the connection? I'm just using standard FTP. Thanks.

    Read the article

  • What are these CPU cache settings? Snoop Filter, ACL prefetch, HW prefetch

    - by eater
    I was in my BIOS setup turning on VT-x support today and saw these other settings. A little googling indicates that they each seem to turn on some sort of optimization to do with the CPU's L2 cache. They were all turned off by default. The processor in question is an Intel Xeon quad-core 3.4GHz (X5492). My OS is Linux 2.6.35.10-74.fc14.x86_64 #1 SMP Thu Dec 23 16:04:50 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux. I have 4GB of RAM if that matters. Here's what the BIOS manufacturer has to say: Snoop Filter Enabling the snoop filter typically improves performance by reducing snoop traffic on the frontside bus in dual processor configurations. Well I like the sound of improved performance. Why would the BIOS have this off by default? Or by dual processor do they not mean multi-core? Regardless, is there a downside if this is on? ACL Prefetch When enabled, the Adjacent Cache Line Prefetcher fetches both cache lines that comprise a cache line pair when it determines required data is not currently in its cache. When disabled, the processor will only fetch the cache line required by the processor. HW Prefetch Fetches an extra line of data into L2 from external memory. Both of these sound like optimizations that have some drawbacks. What are the reasons to turn them on? What are the reasons to leave them off. Why is the default off?

    Read the article

  • Quel est le bug le plus récalcitrant que vous ayez rencontré ? Improbable ou impossible à reproduire, racontez-nous tout

    Quel est le bug le plus récalcitrant que vous ayez rencontré ? Improbable ou impossible à reproduire, racontez-nous votre meilleure histoire de débogage Si le débogage est l'art d'enlever les bogues, la programmation doit être l'art de les créer. Une expression chère à beaucoup de développeurs qui souligne à quel point le débogage d'une application peut être important et... problématique. C'est ce que relate Patrick Thomson, un développeur blogueur qui raconte ce qu'il qualifie de "meilleure histoire de débogage qu'il ait jamais entendue". Il s'agit d'une mésaventure vécue dans les année 80 par le père de l'auteur, avec un ordinateur ancestrale ut...

    Read the article

  • IBM présente cinq innovations IT qui pourraient changer la vie dans les cinq ans à venir

    IBM présente cinq innovations IT qui pourraient changer la vie Dans les cinq années à venir IBM vient de dévoiler, lors de la cinquième édition de son événement « Next Five in Five », cinq innovations technologiques qui pourraient changer la façon de travailler, de vivre et de jouer au cours des cinq prochaines années. IBM a observé les tendances actuelles, les nouvelles technologies développées et fait le point sur les recherches en cours dans ses laboratoire à travers le monde. S'appuyant sur ces observations, IBM pense pouvoir, dans cinq ans, nous offrir la possibilité d'interagir avec nos amis en 3D, alimenter nos batteries d'ordinateurs, portables et autres avec l'air que nous respir...

    Read the article

  • My “SQL Server” Goals for 2011

    - by NeilHambly
    Having Read a few blogs on various SQL people setting their "Goals" for the Year ahead, and having some clearly defined SQL based goals already in mind. I have decided to share these for others to see and ask me from time-time how I'm progressing with them, so although no particular priorities in mind here are my chosen goals for 2011 SQL conferences & Training Events · SQLCruise (June 2011) Alaska - I'm booked on this one already!! · SQL Master Week # 1 ( April/May 2011) Master...(read more)

    Read the article

  • A new Excel 2010 book for Data Analysis

    - by Marco Russo (SQLBI)
    Microsoft Press just announced the printing of Microsoft Excel 2010: Data Analysis and Business Modeling , which is the third edition of the book written by Wayne L. Winston covering many data analysis and modeling techniques using a very clear problem-solution approach, including a good statistical explanation whenever it is necessary. I suggest this book as a good complement to our Microsoft PowerPivot for Excel 2010: Give Your Data Meaning !...(read more)

    Read the article

  • Does anyone prefer proportional fonts?

    - by Jason Baker
    I was reading the wikipedia article on programming style and noticed something in an argument against vertically aligned code: Reliance on mono-spaced font; tabular formatting assumes that the editor uses a fixed-width font. Most modern code editors support proportional fonts, and the programmer may prefer to use a proportional font for readability. To be honest, I don't think I've ever met a programmer who preferred a proportional font. Nor can I think of any really good reasons for using them. Why would someone prefer a proportional font?

    Read the article

< Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >