Search Results

Search found 634 results on 26 pages for 'phil whittaker'.

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

  • jquery autocomplete() is not working

    - by phil
    <script src="http://code.jquery.com/jquery-latest.js"></script> Search: <input id="example" /> <script> $(document).ready(function(){ var data = "Core Selectors Attributes Traversing Manipulation CSS Events Effects Ajax Utilities".split(" "); $("#example").autocomplete(data); }); </script>

    Read the article

  • PHP - string to image only produces black background

    - by Phil Jackson
    Hi im really having a problem find how to fix this. $string = "foo"; $font = 4; $width = ImageFontWidth($font) * strlen($string); $height = ImageFontHeight($font); $im = @imagecreatetruecolor ($width,$height); $bg = imagecolorallocate($im, 255, 255, 255); $textcolor = imagecolorallocate($im, 0, 0, 0); imagestring($im, 5, 0, 0, $string, $textcolor); imagegif($im, 'somefile.gif', 8); imagedestroy($im); I cannot seem to change the background from black. Does anyone have any ideas?

    Read the article

  • Wordpress ajax conflicts

    - by Phil
    I have problems with wordpress and ajax. The ajax request via jQuery just dont work. Jquery noconflict is enabled and the effects work but the ajax requst dont. Where could be the problem? Thank you!

    Read the article

  • Lose the last 3 chars from string variable

    - by Phil
    if the last 4 chars in my string(result) are " AND" or the last three chars are " OR" I would like to remove these from the string. So far I have am trying result.trimend and a few other methods but am unsure how to get it working. Thanks

    Read the article

  • crashing on iPhone Address API

    - by phil swenson
    Any ideas on why this code would crash (crash location indicated below)? email is a valid NSString*... ([email protected]) +(void)newContactFromEmail:(DetailViewController*)controller email:(NSString*)emailAddress{ ABNewPersonViewController *npvc = [[ABNewPersonViewController alloc] init]; ABRecordRef newPerson = ABPersonCreate(); [self updateEmail:newPerson email:emailAddress]; npvc.displayedPerson = newPerson; npvc.newPersonViewDelegate = controller; [controller.navigationController pushViewController:npvc animated:YES]; } +(void)updateEmail:(ABRecordRef)person email:(NSString*)email{ **crashes Here**---->> ABMutableMultiValueRef multiEmail = ABMultiValueCreateMutableCopy (ABRecordCopyValue(person, kABPersonEmailProperty)); ABMultiValueAddValueAndLabel(multiEmail, email, kABHomeLabel, NULL); ABRecordSetValue(person, kABPersonEmailProperty, multiEmail, nil); CFRelease(multiEmail); }

    Read the article

  • no such file to load -- ruby-mbox (LoadError)

    - by Phil M
    sudo gem install ruby-mbox then I run this require "rubygems" require "ruby-mbox" mbox = Mbox.new("Inbox") and I get this $ ruby mbox_read.rb /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require': no such file to load -- ruby-mbox (LoadError) from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31:in `require' from mbox_read.rb:2 gem server says this ruby-mbox 0.0.2 [rdoc] [www] A simple library to read mbox files. Executables are mbox-daemon, mbox-do. Thanks in advance

    Read the article

  • Loading child entities with JPA on Google App Engine

    - by Phil H
    I am not able to get child entities to load once they are persisted on Google App Engine. I am certain that they are saving because I can see them in the datastore. For example if I have the following two entities. public class Parent implements Serializable{ @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String key; @OneToMany(cascade=CascadeType.ALL) private List<Child> children = new ArrayList<Child>(); //getters and setters } public class Child implements Serializable{ @Id @GeneratedValue(strategy = GenerationType.IDENTITY) @Extension(vendorName="datanucleus", key="gae.encoded-pk", value="true") private String key; private String name; @ManyToOne private Parent parent; //getters and setters } I can save the parent and a child just fine using the following: Parent parent = new Parent(); Child child = new Child(); child.setName("Child Object"); parent.getChildren().add(child); em.persist(parent); However when I try to load the parent and then try to access the children (I know GAE lazy loads) I do not get the child records. //parent already successfully loaded parent.getChildren.size(); // this returns 0 I've looked at tutorial after tutorial and nothing has worked so far. I'm using version 1.3.3.1 of the SDK. I've seen the problem mentioned on various blogs and even the App Engine forums but the answer is always JDO related. Am I doing something wrong or has anyone else had this problem and solved it for JPA?

    Read the article

  • String date time format

    - by Phil
    Hi i am using the vimeo API and i want to convert the string to a short date formate {0:d} or {0:dd/mm/yyyy}. This is my code but doesnt seem to be working for me. select new VimeoVideo { Date = String.Format("{0:d}",(item.Element("upload_date").Value)), }; return Vids.ToList(); } public class VimeoVideo { public string Date { get; set; } } Any help would be much appreciated Thanks

    Read the article

  • javascript validate zip regular expression

    - by phil
    It's not working. Probably it's syntax error, but I can't figure it out. <script src="jquery-1.4.2.min.js" type="text/javascript"></script> <script> pattern=/^[0-9]{5}$/; if (!pattern.test($('#zip').val)) {$('#zip').append($('<p>',{html: zip is invalid}));} </script> zip (US only): <input type="text" name='zip' id='zip' maxlength="5">

    Read the article

  • Generate Soap Headers with asp.net

    - by Phil
    I am looking for the asp.net vb syntax to write; <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body xmlns:ns1="http://its/foo.wsdl"> With an xmlwriter Any help greatly appreciated, I'm very stuck! Thanks.

    Read the article

  • StructureMap Configuration Per Thread/Request for the Full Dependency Chain

    - by Phil Sandler
    I've been using Structuremap for a few months now, and it has worked great on some smaller (green field) projects. Most of the configurations I have had to set up involve a single implementation per interface. In the cases where I needed to choose a specific implementation at runtime, I created a factory class that used ObjectFactory.GetNamedInstance<(). In the smaller projects, there were few enough of these cases where I was comfortable with the references to ObjectFactory. My understanding is that you want to limit these references as much as possible, and ideally only reference the ObjectFactory once. I am working to refactor a larger codebase to use IOC/StructureMap, and am finding that I may need many of these factory classes with ObjectFactory references to get what I need. Essentially, I am creating a "root service" with the ObjectFactory, so that everything in the dependency chain is managed by the container. The root service is created by name (i.e. "BuildCar", "BuildTruck"), and the services needed deeper in the dependency chain could also be constructed using the same name--so the "IAttachWheels" service could vary based on whether a car or truck is being built. Since the class that depends on IAttachWheels is the same in both configurations, I don't think I can use ConstructedBy in the registry to choose the implementation. Also, to be clear, the IAttachWheels implementations need to be managed by the container as well, because the dependency chain runs fairly deep. I looked briefly at Profiles as an option, but read (here on StackOverflow) that changing profiles essentially changes implementations for all threads. Is there a feature that is similar to profiles that is thread/request specific? Is the factory class that references ObjectFactory approach the right way to go? Any thoughts would be appreciated.

    Read the article

  • WPF Binding to IDictionary<int,MyType>.Values Doesn't Respond to Property Changes?

    - by Phil Sandler
    I am binding a ListView a property that essentially wraps the Values collection (ICollection) on a generic dictionary. When the values in the dictionary change, I call OnNotifyPropertyChanged(property). I don't see the updates on the screen, with no binding errors. When I change the property getter to return the Linq extension dictionary.Values.ToList(), without changing the signature of the property (ICollection) it works with no problem. Any reason why the Values collection bind and notify properly without projecting to an IList<?

    Read the article

  • javascript getElementByName doesn't work

    - by phil
    This simple js script can't set the value of "para". I guess getElementByName doesn't work. But why? <script function fn() { document.getElementById("para").setAttribute("name","hi"); document.getElementByName("hi").setAttribute("value","my value is high"); } </script <html <input type="button" onClick="fn()" value="click me" <input id="para" type="text" / </html

    Read the article

  • Why cant I specify the width and height of a cell in an html table?

    - by Phil
    I am using CSS but for the sake of quick testing i am just using a style tag. This is the code I am trying to implement: echo "<td style='height=10px; width=10px;'>"; it makes sure that the max width of the cell is 10px however the height overflows with the text so becomes very large (high). what I am trying to achieve is any information that is in that cell more than 30 charcters I want to hide so you cant see it. (I know 30 charaters is more than 10px but I am just playing to see if it worked!) Thanks guys.

    Read the article

  • authlogic rails question - how to code for an API

    - by phil swenson
    I have authlogic going on my app, but now I need to have an an API. I don't want to establish a session, just want a user to send in data in a json request such as: {"type":"address","password":"mypassword","name":"my notificaiton name goes here","user":"myusername","text":"my interesting stuff goes here"} So questions - 1) is this a decent approach? 2) how do i do the auth inside my rails controller?

    Read the article

  • Open an external program in Qt with an attached file extension

    - by Phil
    I am making a qt application which allows the user to select a file and then upon clicking ok, start the associated program with the file already loaded. The program I want to start is java based, and I know how to use QProcess to get it to open, I don't know however how to add the file extension which the user is selecting. Any suggestions?

    Read the article

  • TeamCity build triggers don't automatically run

    - by Phil.Wheeler
    I've been playing around with and learning a bit about TeamCity and have the server correctly set up with my .Net MVC project committed in Subversion successfully and build configurations and triggers sorted to kick off when any changes are committed to the repository. TeamCity polls on its default time period and is picking up that changes have been committed, but it is adding these to the queue without actually ever running them. I have to manually click the "Run" button to kick them off. What setting do I need to change in order to ensure that any new changes are automatically run?

    Read the article

  • jquery dynamically genearate element id in a loop

    - by phil
    This is a loop in a function intending to create elements <li> and give each <li> an unique id. But it's not working. I suspect it's a simple syntax error with the use of quote in .attr(). But I can't get a straight answer from Google. for (i=0;i<array.length;i++) { //create HTML element of tag li $('#suggest').append("<li></li>"); $("li").attr("id",'li'+i); $('#li'+i).html(array[i]); }

    Read the article

  • Loading user controls programatically into a placeholder (asp.net)

    - by Phil
    In my .aspx page I have; <%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" AspCompat="True" %> <%@ Register src="Modules/Content.ascx" tagname="Content" tagprefix="uc1" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> </head> <body> <form id="form1" runat="server"> <div> <asp:PlaceHolder ID="Modulecontainer" runat="server"></asp:PlaceHolder> </div> </form> </body> </html> In my aspx.vb I have; Try Dim loadmodule As UserControl loadmodule = Me.LoadControl("~/modules/content.ascx") Modulecontainer.Controls.Add(loadmodule) Catch ex As Exception Response.Write(ex.ToString & "<br />") End Try The result is an empty placeholder and no errors. Thanks a lot for any assistance P.S after Fat_Tony's answer I changed the code to; Try Dim loadmodule As ASP.ContentModule loadmodule = CType(LoadControl("~\Modules\Content.ascx"), ASP.ContentModule) Modulecontainer.Controls.Add(loadmodule) Catch ex As Exception Response.Write(ex.ToString & "<br />") End Try But still no results unfortunately.

    Read the article

  • linq to xml return second element

    - by Phil
    Hi Im trying to return to the second element in the xml from flickr. This always returns the first element: ImageUrl = item.Element(ns + "link").Attribute("href").Value, and this errors? ImageUrl = item.Elements(ns + "link")[1].Attribute("href").Value, Thanks

    Read the article

  • How to go about writing this classic asp in asp.net

    - by Phil
    I am stuck in converting this snipped to asp.net. set RSLinksCat = conn.Execute("select linkscat.id, linkscat.category from linkscat, contentlinks, links where contentlinks.linksid = links.id and contentlinks.contentid = " & contentid & " and links.linkscatid = linkscat.id order by linkscat.category") <%if not RSLinksCat.EOF then%><h1>Links</h1> <br /> <%do while not RSLinksCat.EOF%> <%set RSLinks = conn.Execute("select * from links where linkscatid = " & RSLinksCat("id") & "")%> <strong><%=RSlinkscat("category")%><strong> <ul> <%do while not RSlinks.EOF%> <li> <a href = "http://<%=RSLinks("url")%>" target="_blank"><%=RSlinks("description")%></a> </li> <%RSLinks.MoveNext loop%> </ul> <%RSLinksCat.MoveNext loop%> <br /> <%end if%><%conn.close%> I'm not sure where to start. Can anyone recommend the correct approach i.e sqldatareaders or repeaters or arrays or? VB code samples most welcome. Thanks

    Read the article

  • Hovering a div shows hidden div - jquery to prototype conversion

    - by phil
    I may get killed for this but I have been trying for a few days using Prototype to show a hidden div when hovering over another div. I have this working fine in jquery but I could use some help porting it over to prototype. The code sample: <script type="text/javascript"> $(document).ready(function(){ $(".recent-question").hover(function(){ $(this).find(".interact").fadeIn(2.0); }, function(){ $(this).find(".interact").fadeOut(2.0); }); }); </script> <div class="recent-question"> <img src="images/new/img-sample.gif" alt="" width="70" height="60" /> <div class="question-text"> <h3>Heading</h3> <p><a href="#">Yadda Yadda Yadda</p> </div> <div class="interact" style="display:none;"> <ul> <li><a href="#">Choice1</a></li> <li><a href="#">Choice2</a></li> <li><a href="#">Choice3</a></li> </ul> </div> </div> So basically when I hover over a recent-question div i would like the div.interact to fade in or appear at all. The above code is for jquery but I am required to use prototype for this project. Any help converting would be greatly appreciated. Thanks!

    Read the article

  • An example of advanced database search

    - by Phil
    Hi there, im looking for an example script. I saw one yesterday but for the life of me I can't find it again today. The task I have is to allow the user to search 1 database table via input controls on an aspx page where they can select and , or , equals to combine fields, generating the sql on the fly with a stringbuilder or similar. (it runs behind the corp firewall) Please can someone point me in the right direction of an example or tutorial I've been working on the page, but have run into problems. Here is a snippet; If NameSearch.Text IsNot String.Empty And andor1v IsNot "0" Then sql += "Surname LIKE '%" & name & "%' " & andor1v & " " ElseIf NameSearch.Text IsNot String.Empty And andor1v Is "0" Then sql += "Surname LIKE '%" & name & "%' " End If

    Read the article

  • PHP - not sure how to ask - regarding variables and $_POST

    - by Phil
    I have a PHP form. The form works but I'm trying to test to see if a value other than the first item has been selected. I can't figure out how to write the If statement. $products = array( '' => 1, 'Item 2' => 2, 'Item 3' => 3, 'Item 4' => 4, 'Item 5' => 5, 'Item 6' => 6 ); $html = generateSelect('products', $products); function generateSelect($name = '', $options = array()) { $html = '<select name="'.$name.'">'; foreach ($options as $option => $value) { $html .= '<option value='.$value.'>'.$option.'</option>'; } $html .= '</select>'; return $html; } In my table, the drop down box is displayed: <tr> <td style="width:{$left_col_width}; text-align:left; vertical-align:center; padding:{$cell_padding}; font-weight:bold; {$product[3]}">{$product[0]}</td> <td style="text-align:left; vertical-align:top; padding:{$cell_padding};"><select name="{$product[1]}"> <option value="1"></option> <option value="2">Item 2</option> <option value="3">Item 3</option> <option value="4">Item 4</option> <option value="5">Item 5</option> <option value="6">Item 6</option> </select></td> </tr> I use the following if statement to check to see if someone has entered a phone number. if they have not entered a phone number, then the "Phone:" text turns red. How do I do an if statement similar to this to verify that someone has selected a product option from the drop down box? if(!empty($_POST['phone'])) { $phone[2] = clean_var($_POST['phone']); if (function_exists('htmlspecialchars')) $phone[2] = htmlspecialchars($phone[2], ENT_QUOTES); } else { $error = 1; $phone[3] = 'color:#d20128;'; } it seems simple but I can't figure it out.

    Read the article

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