Search Results

Search found 1226 results on 50 pages for 'jack flynn'.

Page 6/50 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • Turning HTML character entities to 'regular' letters... why is it only partially working?

    - by Jack W-H
    I'm using all of the below to take a field called 'code' from my database, get rid of all the HTML entities, and print it 'as usual' to the site: <?php $code = preg_replace('~&#x([0-9a-f]+);~ei', 'chr(hexdec("\\1"))', $code); $code = preg_replace('~&#([0-9]+);~e', 'chr("\\1")', $code); $code = html_entity_decode($code); ?> However the exported code still looks like this: progid:DXImageTransform.Microsoft.AlphaImageLoader(src=’img/the_image.png’); See what's going on there? How many other things can I run on the string to turn them into darn regular characters?! Thanks! Jack

    Read the article

  • jQuery: detecting reaching bottom of scroll doesn't work, only detects the top! :(

    - by Jack Webb-Heller
    Hi folks! So basically my problem is a seemingly simple one. You can see it in action at http://furnace.howcode.com (please note that data is returned via Ajax, so if nothing happens give it a few moments!). What's MEANT to happen, is in the second column when you reach the bottom of scrolling, the next 5 results are returned. But what actually happens is it only returns the 5 results when you hit the TOP of the scroll area. Try it: scroll down, nothing happens. Scroll back up to the top, the results are returned. What's going wrong? Here's my code I'm using: $('#col2').scroll(function(){ if ($('#col2').scrollTop() == $('#col2').height() - $('#col2').height()){ loadMore(); } }); loadMore(); is the function that gets the data and appends it. So what's going wrong here? Thanks for your help! Jack

    Read the article

  • Why use Oracle Application Express for web app?

    - by Jack
    Hi all. I believe we're moving to Oracle Apex for future development. I've read about Oracle Apex on wikipedia and it's pro and con. It seem to me the con outweigh the pro but maybe I'm wrong. I get the sense that Oracle Apex is for DBA with little or no programing knowledge to setup a web app quickly sort like MS Access for none programmer. If you have Oracle Apex working experience, can you share your though? From wikipedia's entry, it doesn't seem like you need to know any programming language at all but just the PL/SQL? edit: Is Oracle Apex scalable? Can it handle traffic like Facebook's size? Thank. Jack

    Read the article

  • iPhone: Using plist to populate a grouped table

    - by Jack Griffiths
    Hi there, I was wanting to use a plist to populate my grouped table. I've had a look at the DrillDownSave sample project, and I'm still none-the-wiser. Although, I did learn that I could store hierarchies and suchlike in there. So here's the questions: How can I use my plist to add new items to my grouped table? I'm currently feeding the table with an array, and I've noticed that an array isn't going to be the best thing for me. When a user taps on an item in the plist, how can I push the view to the corresponding item? In other words, how can I push the view based on the selected row (which was generated by the plist) to it's next "view"? If that makes any sense, please reply. Thanks, Jack.

    Read the article

  • Using plist to populate a grouped table

    - by Jack Griffiths
    Hi there, I was wanting to use a plist to populate my grouped table. I've had a look at the DrillDownSave sample project, and I'm still none-the-wiser. Although, I did learn that I could store hierarchies and suchlike in there. So here's the questions: How can I use my plist to add new items to my grouped table? I'm currently feeding the table with an array, and I've noticed that an array isn't going to be the best thing for me. When a user taps on an item in the plist, how can I push the view to the corresponding item? In other words, how can I push the view based on the selected row (which was generated by the plist) to it's next "view"? If that makes any sense, please reply. Thanks, Jack.

    Read the article

  • how to added a GUI to my class

    - by Gerard Flynn
    hi i have a class that runs, it does the following backups a sql, zip, encrypts, ftp to an ftp server. what i want to do is add a GUI. Need to add a 2 buttons start and finish and progress bar for the procedure. my class is called backup.cs. i have tried creating a form but doesn't seam to work. any help would be great full Ta Gerard

    Read the article

  • CodeIgniter's XSS Protection is removing <script> tags from user inputs... but I don't want it to!

    - by Jack W-H
    Hey folks, CodeIgniter is brilliant but I'm using it to develop a site where users need to be able to share their code for websites. Unfortunately, CodeIgniter has been doing the "right" thing by removing <script> tags from my user's inputs into the database, so when it's returned data looks like this: [removed] User's data [removed] However, I need my site to DISPLAY script tags but obviously not PARSE them. How can I get CodeIgniter or PHP to return <script> tags, but still sanitise them for the database and return them without them executing? Thanks! Jack EDIT: By the way, it's not an option to use stuff like Markdown, everything has to output to copy-pastable code that could work with no modification somewhere else

    Read the article

  • iPhone: error: request for member 'table' in something not a structure or union

    - by Jack Griffiths
    Hi there, When it comes to compiling my application, I get the error mentioned in the title. How would I go about remedying this error? Basically, I want to get from one table to the other. Hierarchy, navigation. NextViewController.m #import "RootViewController.h" #import "NextViewController.h" @implementation NextViewController - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; // Releases the view if it doesn't have a superview // Release anything that's not essential, such as cached data } - (void)dealloc { [super dealloc]; } - (IBAction) changeTable:(NSString *)str{ tblCSS.table = str; } The last line contains the error. If you need any more code, just ask. I'll amend this post with it. Cheers, Jack

    Read the article

  • Entity Framework does not display the last change from the database

    - by Jack
    Entity Framework does not display the last change from the database, but after sometime it show the updated content. I don't any special change on the server or on the page. Thank in advance. Jack Here is the code i use to get the list: var m = from r in ett.Article_Relations from i in ett.Article_Articles from a in ett.Article_Contents where r.MenuItemID == id && r.Article_Articles.ArticleID == i.ArticleID && a.LanguageID == LanguageID && i.ArticleID == a.Article_Articles.ArticleID select new ArticleViewModel { ArticleID = i.ArticleID, IsActive = i.IsActive, Author = i.ArticleAuthor, Content = a, DateCreated = i.DateCreated };

    Read the article

  • Security precautions and techniques for a User-submitted Code Demo Area

    - by Jack W-H
    Hey folks Maybe this isn't really feasible. But basically, I've been developing a snippet-sharing website and I would like it to have a 'live demo area'. For example, you're browsing some snippets and click the Demo button. A new window pops up which executes the web code. I understand there are a gazillion security risks involved in doing this - XSS, tags, nasty malware/drive by downloads, pr0n, etc. etc. etc. The community would be able to flag submissions that are blatantly naughty but obviously some would go undetected (and, in many cases, someone would have to fall victim to discover whatever nasty thing was submitted). So I need to know: What should I do - security wise - to make sure that users can submit code, but that nothing malicious can be run - or executed offsite, etc? For your information my site is powered by PHP using CodeIgniter. Jack

    Read the article

  • Validate a number between 10 and 11 characters in length

    - by Montana Flynn
    I am using javascript (and PHP) to validate a simple form with a phone number field. I have it working fine checking that the field has only 10 characters, but I really want to check if the field has between 10 and 11 characters. Reason being, some people type numbers like so: 1 555 555 5555 and some people do this 555 555 5555. Here is what I have that works for checking if the length is 10: if (!(stripped.length == 10)) { alert("Please enter a valid US phone number.") return false }

    Read the article

  • Rails CSV import, adding to a related table

    - by Jack
    Hi, I have a csv importing system on my app (used locally only) which parses the csv file line by line and adds the data to the database table. This is based on a tutorial here. require 'csv' def csv_import @parsed_file=CSV::Reader.parse(params[:dump][:file]) n = 0 @parsed_file.each_with_index do |row, i| next if i == 0 #ignore the first row course = Course.new course.title = row[0] course.unit_code = row[1] course.course_type = row[2] course.value = row[3] course.pass_mark = row[4] if course.save n = n+1 GC.start if n%50==0 end flash.now[:message] = "CSV Import Successful, #{n} new courses added to the database." end redirect_to(courses_url) end This is all in the courses controller and works fine. There is a relationship that courses HABTM years and years HABTM courses. In the csv file (effectively in row[5] to row[8]) are the year_id s. Is there a way that I can add this within the method above. I am confused as to how to loop over the 4 items and add them to the courses_years table. Thank you Jack

    Read the article

  • iPhone: Navigation Bar button indefinitely links to it's own view.

    - by Jack Griffiths
    Hi there, When I navigate from the root view to another view, it works. However, when I want to get back, the navigation button links to itself. This goes on for about 6 taps, until it eventually goes back to the root view. This only occurs on one view, and the rest are working fine. I have no idea what code is causing this, but if you need any code, I will amend this post with it. Just ask for it. Thanks a lot, Jack.

    Read the article

  • Django how to handle # in variable name.

    - by Jack
    I've got a dictionary in python which is assigned as a template variable. One of the keys is named "#text" but when i try to access it using {{ artist.image.3."#text"}} I get an error which is File "/home/jack/Desktop/test/appengine/lib/django/django/template/__init__.py", line 558, in __init__ raise TemplateSyntaxError, "Could not parse the remainder: %s" % token[upto:] TemplateSyntaxError: Could not parse the remainder: "#text" So how can I use this in the template? I've tried putting quotes around it but to no avail. I'd like to not modify the dictionary if possible, but if its easy enough to do then I guess its okay. Thanks

    Read the article

  • destroy an android service

    - by Jack Trowbridge
    I am using a service in my android app, which is called when an alarm is activated by a calander. When the service has been activated i want it to be destroyed by the OnStart() method once it has completed its code. My OnStart() method: @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); Vibrator vi = (Vibrator) getSystemService(Context.VIBRATOR_SERVICE); vi.vibrate(5000); Toast.makeText(this, "MyAlarmService.onStart()", Toast.LENGTH_LONG).show(); //CODE HERE TO DESTROY SERVICE?? } This bassically means when the service is called it runs the code in the OnStart() method and i want it to destroy itself. Any Ideas, methods that would do this?. Thanks, jack.

    Read the article

  • Counting the most tagged tag with MySQL

    - by Jack W-H
    Hi folks My problem is that I'm trying to count which tag has been used most in a table of user-submitted code. But the problem is with the database structure. The current query I'm using is this: SELECT tag1, COUNT(tag1) AS counttag FROM code GROUP BY tag1 ORDER BY counttag DESC LIMIT 1 This is fine, except, it only counts the most often occurence of tag1 - and my database has 5 tags per post - so there's columns tag1, tag2, tag3, tag4, tag5. How do I get the highest occurring tag value from all 5 columns in one query? Jack

    Read the article

  • T4MVC adding current page controller to action link

    - by Mike Flynn
    I have the following ActionLink that sits in the home page on the register controller (Index.cshtml) @Html.ActionLink("terms of service", Url.Action(MVC.Home.Terms()), null, new { target="_blank" }) Generating the following URL. Why is "register" being added to it? It's as if the link within the Register page which has it's own controller is preappending the register controller to any link in that view? http://localhost/register/terms-of-service routes.MapRoute( "Terms", "terms-of-service", new { controller = "Home", action = "Terms" } ); public partial class HomeController : SiteController { public virtual ActionResult Terms() { return View(new SiteViewModel()); }

    Read the article

  • AJAX response inside jqplot not working

    - by JuanGesino
    I'm trying to render data from an AJAX response as a bar chart with jqplot. To render this bar chart I use two variables: s1 which contains the numbers ex: s1 = [22,67,32,89] ticks which contains the name corresponding to a number inside s1 ex: ticks = ["Jack", "Mary", "Paul", "John"] So my AJAX returns two variables, data1 and data2. When I console.log(data1) I get 22,67,32,89 When I console.log(data2) I get "Jack", "Mary", "Paul", "John" I then add the square brackets and change variable: s1 = [data1] ticks = [data2] When I console.log(s1) I get ["22,67,32,89"] When I console.log(ticks) I get "Jack", "Mary", "Paul", "John" And the graph does not render, this is my code: s1 = [data]; ticks = [data]; plot4 = $.jqplot('chartdiv4', [s1], { animate: !$.jqplot.use_excanvas, series:[{color:'#5FAB78'}], seriesDefaults:{ renderer:$.jqplot.BarRenderer, pointLabels: { show: true } }, axes: { xaxis: { renderer: $.jqplot.CategoryAxisRenderer, ticks: ticks }, yaxis:{min:0, max:100, label:'%',labelRenderer: $.jqplot.CanvasAxisLabelRenderer} }, highlighter: { show: false } }); });

    Read the article

  • Facebook JS SDK FB.logout() doesn't terminate user session

    - by Casey Flynn
    I'm attempting to log a user out of facebook with the Facebook JS SDK, however calling: FB.logout(function(response){ console.log(response); }); returns: response.status == "connected" And only after refreshing the page does the SDK realize that the session has ended. Anyone know what could be causing this behavior? This code previously worked in my application and has recently started behaving this way. Another example using FireBug:

    Read the article

  • iPhone: App crashes when I click on a cell in table view.

    - by Jack Griffiths
    Hi there, Compiling my application works—everything is fine. The only errors I get are by deprecated functions (setText). The only problem is now, is that when I tap on a cell in my table, the app crashes, even though it's meant to push to the next view in the stack. Any solutions are appreciated, if you need any code, just ask. Also, how can I only make sure that one cell goes to only one view? For example: When I tap on CSS, it takes me to a new table with different levels of CSS. WHen I tap on an item in that new view, it comes up with an article on what I just selected. Regards, Jack

    Read the article

  • Query to retrieve records by aplhabetic order, except for n predefined items which must be on top

    - by Ashraf Bashir
    I need to retrieve all records ordered alphabetically. Except for a predefined list of record's columns which their records should appear first in a given predefined order, then all other records should be sorted alphabetically based on the same column For instance, assume we have the following table which is called Names Lets assume the predefined list is ("Mathew", "Ashraf", "Jack"). I.e. these are the names of whom their records should be listed first as in the predefined order. So the desired query result should be: Which query could retrieve this custom order ? P.S, I'm using MySQL. Here's my trial based on comments' request: (SELECT * FROM Names WHERE Name in ('Mathew', 'Ashraf', 'Jack')) UNION (SELECT * FROM Names WHERE Name NOT IN ('Mathew', 'Ashraf', 'Jack') ORDER BY Name ASC); the first query result wasn't ordered as required.

    Read the article

  • Passing an array of data to a private function in CodeIgniter/PHP? [facepalm]

    - by Jack Webb-Heller
    So I thought this should be easy, but, I'm n00bing out here and failing epicly (as they say on teh interwebz). So here's my code: function xy() { $array['var1'] = x; $array['var2'] = y; echo $this->_z; } function _z($array) { $xy = $x.$y; return $xy; } So, why doesn't that seemingly simple code work? I know with views you can pass arrays and the variables are accessible in the views with just their array title, but, why doesn't it work in this case? Jack

    Read the article

  • Python how to handle # in a dictionary

    - by Jack
    I've got some json from last.fm's api which I've serialised into a dictionary using simplejson. A quick example of the basic structure is below. { "artist": "similar": { "artist": { "name": "Blah", "image": {"#text":"URLHERE","size": "small"} "image": {"#text":"URLHERE","size": "medium"} "image": {"#text":"URLHERE","size": "large"} } } } Any ideas how I can access the image urls of various different sizes. My attempts at accessing the #text variable don't seem to work because python doesn't appear to like #'s in the names. And any ideas how I can easily get the url for the depending on the size? Thanks, Jack

    Read the article

  • How can I share code across static libraries without duplicate symbol errors?

    - by Ben Flynn
    I am new to building static libraries and would like to create 2(+) libraries each of which has some unique code and some shared code. My intention is that other projects will link one or more of these static libraries. Util.h/m <-- Shared ImplOne.h/m <-- Unique to 'ImplOne' ImplTwo.h/m <-- Unique to 'ImplTwo' I am using XCode and generating the libraries by building Util.m and ImplOne.m in one case, and Util.m and ImplTwo.m in the other. Of course the issue is that I now cannot use these libraries together because they will have duplicate symbols. What is a better architecture for this situation?

    Read the article

  • knockout.js with optionsValue and value

    - by Mike Flynn
    Is there a way to keep the value binding to the object, but have the optionsValue be a property on the object. As of now if I specify both, the optionsValue property that is selected will populate the value binding. Id like to keep the object intact in the observable, but specify what value to be set in the select list value. This way a form submit will send the optionsValue I chose. @Html.DropDownListFor(q => q.DivisionId, new SelectList(Enumerable.Empty<string>()), new { data_bind="options: divisions, optionsText: 'Name', optionsValue: 'Id', value: division, optionsCaption: ' - '" }) function AddCrossPoolGameDialog() { var self = this; self.divisions = ko.observableArray([]); self.division = ko.observable(); self.awayDivisionTeams = ko.computed(function () { var division = ko.utils.arrayFirst(self.divisions(), function(item) { return self.division.Name() == item.Name; }); if (division) { return division.DivisionTeamPools; } return []; }); }

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >