Search Results

Search found 3747 results on 150 pages for '500'.

Page 56/150 | < Previous Page | 52 53 54 55 56 57 58 59 60 61 62 63  | Next Page >

  • js works inside the page but not in code behind

    - by Cristian Boariu
    Hi guys, I have this function put in a MasterPage, which shows up an mp3 player: <script type="text/javascript"> $(document).ready(function() { var stageW = 500; var stageH = 216; var cacheBuster = Date.parse(new Date()); var flashvars = {}; var params = {}; params.bgcolor = '#F6F6F6'; params.allowfullscreen = 'true'; flashvars.stageW = stageW; flashvars.stageH = stageH; flashvars.pathToFiles = ''; flashvars.settingsPath = '../mp3player/mp3player_settings.xml'; flashvars.xmlPath = '<%# getRestXmlPlayerUrl() %>'; flashvars.keepSelected = 't'; flashvars.selectedWindow = '4'; flashvars.slideshow = 't'; flashvars.imageWidth = '130'; flashvars.imageHeight = '130'; swfobject.embedSWF('swf/preview.swf?t=' + cacheBuster, 'myContent', stageW, stageH, '9.0.124', 'swf/expressInstall.swf', flashvars, params); }); </script> All works great. But, because i have some ajax on the page with update panel, the flash in not rendered when ajax requests occurs so i need to register this function and i've tried something like this: protected void Page_PreRender(object sender, EventArgs e) { Type cstype = this.GetType(); String csnameForPlayer = "applyStyleToMp3Player"; if (!Page.ClientScript.IsClientScriptBlockRegistered(cstype, csnameForPlayer)) { StringBuilder cstextForPlayer = new StringBuilder(); cstextForPlayer.Append(" $(document).ready(function() { " + " var stageW = 500;" + " var stageH = 216;" + " var cacheBuster = Date.parse(new Date());" + " var flashvars = {};" + " var params = {};" + " params.bgcolor = '#F6F6F6';" + " params.allowfullscreen = 'true';" + " flashvars.stageW = stageW;" + " flashvars.stageH = stageH;" + " flashvars.pathToFiles = '';" + " flashvars.settingsPath = '../mp3player/mp3player_settings.xml';" + " flashvars.xmlPath = '<%# getRestXmlPlayerUrl() %>';" + " flashvars.keepSelected = 't';" + " flashvars.selectedWindow = '4';" + " flashvars.slideshow = 't';" + " flashvars.imageWidth = '130';" + " flashvars.imageHeight = '130';" + " swfobject.embedSWF('swf/preview.swf?t=' + cacheBuster, 'myContent', stageW, stageH, '9.0.124', 'swf/expressInstall.swf', flashvars, params);" + "}); "); ScriptManager.RegisterStartupScript(this.Page, this.Page.GetType(), csnameForPlayer, cstextForPlayer.ToString(), true); } } Well, this does not work. The flash player does not appear any more, so, i assume that is something wrong in the cstextForPlayer. I've spent over one hour to figure it out but i've failed. Does anyone see the problem? Thanks in advance.

    Read the article

  • Timer in a Windows service - not really working?

    - by marc_s
    I have a Windows NT Service in C# which basically wakes up every x seconds, checks to see if any mail notifications need to be sent out, and then goes back to sleep. It looks something like this (the Timer class is from the System.Threading namespace): public partial class MyService : ServiceBase { private Timer _timer; private int _timeIntervalBetweenRuns = 10000; public MyService() { InitializeComponent(); } protected override void OnStart(string[] args) { // when NT Service starts - create timer to wake up every 10 seconds _timer = new Timer(OnTimer, null, _timeIntervalBetweenRuns, Timeout.Infinite); } protected override void OnStop() { // on stop - stop timer by freeing it _timer = null; } private void OnTimer(object state) { // when the timer fires, e.g. when 10 seconds are over // stop the timer from firing again by freeing it _timer = null; // check for mail and sent out notifications, if required - works just fine MailHandler handler = new MailHandler(); handler.CheckAndSendMail(); // once done, re-enable the timer by creating it from scratch _timer = new Timer(OnTimer, null, _timeIntervalBetweenRuns, _timeIntervalBetweenRuns); } } Sending the mail and all works just fine, and the service also wakes up every 10 seconds (in reality, this is a setting from a config file - simplified for this example). However, at times, the service seems to wake up too quickly.... 2010-04-09 22:50:16.390 2010-04-09 22:50:26.460 2010-04-09 22:50:36.483 2010-04-09 22:50:46.500 2010-04-09 22:50:46.537 ** why again after just 37 milliseconds...... ?? 2010-04-09 22:50:56.507 Works fine to 22:50:45.500 - why does it log another entry just 37 milliseconds later?? Here, it seems it's totally out of whack.... seems to wake up twice or even three times every time 10 seconds are over.... 2010-04-09 22:51:16.527 2010-04-09 22:51:26.537 2010-04-09 22:51:26.537 2010-04-09 22:51:36.543 2010-04-09 22:51:36.543 2010-04-09 22:51:46.553 2010-04-09 22:51:46.553 2010-04-09 22:51:56.577 2010-04-09 22:51:56.577 2010-04-09 22:52:06.590 2010-04-09 22:52:06.590 2010-04-09 22:52:06.600 2010-04-09 22:52:06.600 Any ideas why?? It's not a huge problem, but I'm concerned it might start to put too much load on the server, if the interval I configure (10 seconds, 30 seconds - whatever) seems to be ignored more and more, the longer the service runs. Have I missed something very fundamental in my service code?? Am I ending up with multiple timers, or something?? I can't seem to really figure it out..... have I picked the wrong timer (System.Threading.Timer) ? There's at least 3 Timer classes in .NET - why?? :-)

    Read the article

  • How can I return a link to an active state after mouseout?

    - by Craig
    var menuEnter = { 'color': hoverColor}; var menuLeave = { 'color': 'C0C0C0'}; new ('div#menu a.level1 span.bg', menuEnter, menuLeave, { transition: Fx.Transitions.linear, duration: 200 }, { transition: Fx.Transitions.sineIn, duration: 500 }); I would like the active menu color to not be affected by the mouseleave var. Thank you.

    Read the article

  • JQUERY, scrollTo, after scrolling down, the page won't let me scroll up for a second... Y?

    - by nobosh
    I'm using the following JQUERY to attach an even to a link in the header, which essentially scrolls to the bottom of the page: $('#comment-count-btn').click(function(){ $('html,body').scrollTo('#comment-wrapper', 500); }); Problem is, that it scrolls all the way to the bottom of the page (which is correct), but then when I try to scroll up a tad, the scroll bar jumps, as if it's locked for a little bit. Any ideas?

    Read the article

  • Ruby Mechanize - Basic Get Failing

    - by hutch
    a = WWW::Mechanize.new { |agent| agent.user_agent_alias = 'Mac Safari' agent.history.max_size=0 } page = a.get('http://livingsocial.com/deals?preferred_city=18') Trying a very basic GET request using mechanize but get a 500, yet when I CURL I have no problems. Is there a problem with including parameters in a get() call? I know I am missing something simple

    Read the article

  • Solving simultaneous equations

    - by Milo
    Here is my problem: Given x, y, z and ratio where z is known and ratio is known and is a float representing a relative value, I need to find x and y. I know that: x / y == ratio y - x == z What I'm trying to do is make my own scroll pane and I'm figuring out the scrollbar parameters. So for example, If the scrollbar must be able to scroll 100 values (z) and the thumb must consume 80% of the bar (ratio = 0.8) then x would be 400 and y would be 500. Thanks

    Read the article

  • WPF using Frame to show a WebSite - flash problem

    - by H4mm3rHead
    Hi, I have a small problem. I use a Frame to show a website, unfortunateli some of my websites use flash, and seems to want to install a flash plugin - my frame doesnt seem to accept this behavior so it fails giving me a http 500 internal server error. Any one having any experiences in how to show the web site or install the flash plugin (its already installed in my regular IE - i can browse the site without problems)

    Read the article

  • Python urllib.urlopen() call doesn't work with a URL that a browser accepts

    - by Charles Anderson
    If I point Firefox at http://bitbucket.org/tortoisehg/stable/wiki/Home/ReleaseNotes, I get a page of HTML. But if I try this in Python: import urllib site = 'http://bitbucket.org/tortoisehg/stable/wiki/Home/ReleaseNotes' req = urllib.urlopen(site) text = req.read() I get the following: 500 Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. What am I doing wrong?

    Read the article

  • Strange error from mysql storage engine

    - by zerkms
    General error: 1030 Got error -1 from storage engine the used storage engine is innodb the query was runned when i got it today morning was: SELECT feeds.* FROM feeds ORDER BY RAND() LIMIT 1 i know rand() is bad but it's very small table (<500 records) and not loaded project this error i receive approximately once a day. cannot google anything relevant :-(

    Read the article

  • PHPMailer - what sending method is most appropriate?

    - by Stomped
    Hello. I need to use PHPMailer to send emails out for the following reasons: small lists (less then 500) password resets general notifications, 100ish emails at a time And PHPMailer gives me the option to send via mail(), sendmail, or SMTP. Is there any reason to prefer one of these methods over the other? I don't know enough about email services in general to make an informed decision.

    Read the article

  • jQuery post request is not sent until first post request is compleated

    - by Champ
    I have a function which have a long execution time. public void updateCampaign() { context.Session[processId] = "0|Fetching Lead360 Campaign"; Lead360 objLead360 = new Lead360(); string campaignXML = objLead360.getCampaigns(); string todayDate = DateTime.Now.ToString("dd-MMMM-yyyy"); context.Session[processId] = "1|Creating File for Lead360 Campaign on " + todayDate; string fileName = HttpContext.Current.Server.MapPath("campaigns") + todayDate + ".xml"; objLead360.createFile(fileName, campaignXML); context.Session[processId] = "2|Reading The latest Lead360 Campaign"; string file = File.ReadAllText(fileName); context.Session[processId] = "3|Updating Lead360 Campaign"; string updateStatus = objLead360.updateCampaign(fileName); string[] statusArr = updateStatus.Split('|'); context.Session[processId] = "99|" + statusArr[0] + " New Inserted , " + statusArr[1] + " Updated , With " + statusArr[2] + " Error , "; } So to track the Progress of the function I wrote a another function public void getProgress() { if (context.Session[processId] == null) { string json = "{\"error\":true}"; Response.Write(json); Response.End(); }else{ string[] status = context.Session[processId].ToString().Split('|'); if (status[0] == "99") context.Session.Remove(processId); string json = "{\"error\":false,\"statuscode\":" + status[0] + ",\"statusmsz\":\"" + status[1] + "\" }"; Response.Write(json); Response.End(); } } To call this by jQuery post request is used reqUrl = "AjaxPages/lead360Campaign.aspx?processid=" + progressID + "&action=updatecampaign"; $.post(reqUrl); setTimeout(getProgress, 500); get getProgress is : function getProgress() { reqUrl = "AjaxPages/lead360Campaign.aspx?processid=" + progressID + "&action=getProgress"; $.post(reqUrl, function (response) { var progress = jQuery.parseJSON(response); console.log(progress) if (progress.error) { $("#fetchedCampaign .waitingMsz").html("Some error occured. Please try again later."); $("#fetchedCampaign .waitingMsz").css({ "background": "url(common/images/ajax_error.jpg) no-repeat center 6px" }); return; } if (progress.statuscode == 99) { $("#fetchedCampaign .waitingMsz").html("Update Status :"+ progress.statusmsz ); $("#fetchedCampaign .waitingMsz").css({ "background": "url(common/images/ajax_loded.jpg) no-repeat center 6px" }); return; } $("#fetchedCampaign .waitingMsz").html("Please Wait... " + progress.statusmsz); setTimeout(getProgress, 500); }); } But the problem is that I can't see the intermediate message. Only the last message is been displayed after a long lime of ajax loading message Also on the browser console I just see that after a long time first requested is completed and after that the second request is completed. but there should be for getProgress ? I have checked jquery.doc and it says that $post is an asynchronous request. Can anyone please explain what is wrong with the code or logic?

    Read the article

  • rewrite rule for codeigniter

    - by John
    this is my controller in CI class Welcome extends Controller { function Welcome() { parent::Controller(); } function index() { } function bil($model='') { } I want to do a rewrite so that http://example.com/index.php/welcome/bil/model becomes http://example.com/model in my htaccess I have RewriteBase / RewriteCond $1 !^(index\.php|images|robots\.txt) RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /index.php/welcome/$1 [L] #RewriteRule ^(.*)$ /index.php/welcome/bil/$1 [L] I thought it should be as easy as removing the /index.php/welcome/ part but when I uncomment the last line it get 500 internal server error

    Read the article

  • SQL: GROUP BY after JOIN without overriding rows?

    - by krismeld
    I have a table of basketball leagues, a table af teams and a table of players like this: LEAGUES ID | NAME | ------------------ 1 | NBA | 2 | ABA | TEAMS: ID | NAME | LEAGUE_ID ------------------------------ 20 | BULLS | 1 21 | KNICKS | 2 PLAYERS: ID | TEAM_ID | FIRST_NAME | LAST_NAME | --------------------------------------------- 1 | 21 | John | Starks | 2 | 21 | Patrick | Ewing | Given a League ID, I would like to retrieve all the players' names and their team ID from all the teams in that league, so I do this: SELECT t.id AS team_id, p.id AS player_id, p.first_name, p.last_name FROM teams AS t JOIN players AS p ON p.team_id = t.id WHERE t.league_id = 1 which returns: [0] => stdClass Object ( [team_id] => 21 [player_id] => 1 [first_name] => John [last_name] => Starks ) [1] => stdClass Object ( [team_id] => 21 [player_id] => 2 [first_name] => Patrick [last_name] => Ewing ) + around 500 more objects... Since I will use this result to populate a dropdown menu for each team containing each team's list of players, I would like to group my result by team ID, so the loop to create these dropdowns will only have to cycle through each team ID instead of all 500+ players each time. But when I use the GROUP BY like this: SELECT t.id AS team_id, p.id AS player_id, p.first_name, p.last_name FROM teams AS t JOIN players AS p ON p.team_id = t.id WHERE t.league_id = 1 GROUP BY t.id it only returns one player from each team like this, overriding all the other players on the same team because of the use of the same column names. [0] => stdClass Object ( [team_id] => 21 [player_id] => 2 [first_name] => Patrick [last_name] => Ewing ) [1] => stdClass Object ( [team_id] => 22 [player_id] => 31 [first_name] => Shawn [last_name] => Kemp ) etc... I would like to return something like this: [0] => stdClass Object ( [team_id] => 2 [player_id1] => 1 [first_name1] => John [last_name1] => Starks [player_id2] => 2 [first_name2] => Patrick [last_name2] => Ewing +10 more players from this team... ) +25 more teams... Is it possible somehow?

    Read the article

  • If a jQuery function calls itself in its completion callback, is that a recursive danger to the stac

    - by NXT
    Hi, I'm writing a little jQuery component that animates in response to button presses and also should go automatically as well. I was just wondering if this function recursive or not, I can't quite work it out. function animate_next_internal() { $('#sc_thumbnails').animate( { top: '-=106' }, 500, function() { animate_next_internal(); } ); } My actual function is more complicated to allow for stops and starts, this is just a simplified example.

    Read the article

  • Problem on a Floyd-Warshall implementation using c++

    - by Henrique
    I've got a assignment for my college, already implemented Dijkstra and Bellman-Ford sucessfully, but i'm on trouble on this one. Everything looks fine, but it's not giving me the correct answer. Here's the code: void FloydWarshall() { //Also assume that n is the number of vertices and edgeCost(i,i) = 0 int path[500][500]; /* A 2-dimensional matrix. At each step in the algorithm, path[i][j] is the shortest path from i to j using intermediate vertices (1..k-1). Each path[i][j] is initialized to edgeCost(i,j) or infinity if there is no edge between i and j. */ for(int i = 0 ; i <= nvertices ; i++) for(int j = 0 ; j <= nvertices ; j++) path[i][j] = INFINITY; for(int j = 0 ; j < narestas ; j++) //narestas = number of edges { path[arestas[j]->v1][arestas[j]->v2] = arestas[j]->peso; //peso = weight of the edge (aresta = edge) path[arestas[j]->v2][arestas[j]->v1] = arestas[j]->peso; } for(int i = 0 ; i <= nvertices ; i++) //path(i, i) = 0 path[i][i] = 0; //test print, it's working fine //printf("\n\n\nResultado FloydWarshall:\n"); //for(int i = 1 ; i <= nvertices ; i++) // printf("distancia ao vertice %d: %d\n", i, path[1][i]); //heres the problem, it messes up, and even a edge who costs 4, and the minimum is 4, it prints 2. //for k = 1 to n for(int k = 1 ; k <= nvertices ; k++) //for i = 1 to n for(int i = 1 ; i <= nvertices ; i++) //for j := 1 to n for(int j = 1 ; j <= nvertices ; j++) if(path[i][j] > path[i][k] + path[k][j]) path[i][j] = path[i][k] + path[k][j]; printf("\n\n\nResultado FloydWarshall:\n"); for(int i = 1 ; i <= nvertices ; i++) printf("distancia ao vertice %d: %d\n", i, path[1][i]); } im using this graph example i've made: 6 7 1 2 4 1 5 1 2 3 1 2 5 2 5 6 3 6 4 6 3 4 2 means we have 6 vertices (1 to 6), and 7 edges (1,2) with weight 4... etc.. If anyone need more info, i'm up to giving it, just tired of looking at this code and not finding an error.

    Read the article

  • How do you throw an HTTP error with mod_python

    - by Zxaos
    I have a setup where I'm serving simple python pages using the mod_python publisher. At some points I'd like to have the python function raise a standard apache error - for example throwing a 500 error if a required file is missing. How can I throw an apache error from within a mod_python script?

    Read the article

  • uploading problem

    - by Syom
    i can't upload large files, but i've set php.ini max_execution_time = 3600 max_input_time = 600 memory_limit = 100M post_max_size = 100M file_uploads = On upload_max_filesize = 100M it returns a 500 error - [an error occurred while processing this directive] could you say why? thanks

    Read the article

  • javascript problem in IE8

    - by Pankaj
    This code is not working on IE8 window.open(url, "find_users", "resizable=yes,scrollbars=yes,menubar=no,toolbar=no,location=no,status=yes,height=300,width=500"); I am getting Object Expected error in only IE8, its working fine in all other brouser.

    Read the article

  • Facebook requests 3 post_authorize/post_remove. How can I stop it?

    - by Ray Yun
    When user authorize or remove application, Facebook always request post_authorize or post_remove callback 3 times. Only I throws HTTP 500 error, it stop calling them. Yeah, it would be easy to ignore subsequent requests when I successfully handled that. So this maybe academic question. Is there any method to stop facebook requests with http status code??? :)

    Read the article

  • how to write a script that logs into an application and checks a page

    - by josh
    Is it possible to write a script that will login to an application using uname/pwd? the username/password are not passed in through POST (they dont come in the URL) Basic steps I am looking for are: Visit url enter uname/pwd click a button click a link get the raw html to make sure it does not have 500 error Is that possible to do in any language? Please point me to some examples as well

    Read the article

< Previous Page | 52 53 54 55 56 57 58 59 60 61 62 63  | Next Page >