I recently built a form that submits data to my database with an ajax function that is called through onClick="function ..." on the submit button. That all works perfectly, however the information shown on the page needs to update to reflect the new data so I made that work by calling another ajax function, which also works. The problem is I also have jQuery in the page. When the page loads the jQuery all works, after the ajax function updates the page (without refreshing the browser) none of the jquery works. Any suggestions?
here's the ajax function for updating the data
Line number On/Off | Expand/Contract // Get the HTTP Objectfunction getHTTPObject(){ if (window.ActiveXObject) return new ActiveXObject("Microsoft.XMLHTTP"); else if (window.XMLHttpRequest) return new XMLHttpRequest(); else { alert("Your browser does not support AJAX."); return null; }} var httpObject = null; // Set up the updating routinefunction displayRegularFeeds(user_id){ httpObject = getHTTPObject(); var fast = "http://localhost/capicy/regularfeeds.php?id="+user_id; if (httpObject != null) { httpObject.open("GET", fast, true); httpObject.send(null); httpObject.onreadystatechange = recieveRegularFeeds; }}// Recieve the time and display itfunction recieveRegularFeeds(){ if(httpObject.readyState == 4){ document.getElementById('regularbox').innerHTML = httpObject.responseText; }}
heres the onclick from the submit button
Line number On/Off | Expand/Contract echo '<input type="button" id="share" name="share" value="Share" class="sharebuttonlink" onClick="javascript:var phrase = document.getElementById('status').value; shareStatus(phrase); displayRegularFeeds(''."$user".'');">';
heres the file displayRegularFeeds executes
Line number On/Off | Expand/Contract include('mysql.php'); include('feeds.php'); feeds('regular', 'home');
Please help!
Script not running properly
Hello EveryoneThis is a basic script for posting to a database. I'm not sure why it doesn't work. Can anyone tell me why?Code: [Select]<?phprequire('config.php');if(isset($_GET['id']) == TRUE
mysql_affected_rows() usage
Possibly a MySQL issue, but the function that is not behaving in the anticipated way is a PHP function.Seems as though mysql_affected_rows() is not returning the desired number so I can move into my
Are sessions secure at all?..
I haven't really gotten into yet, but I was just thinking of something weird..Lets say you have a session element $_SESSION['is_admin']..Is that easy to modify the cookie or whatnot and change it to
background color imagefill
HelloI would like to ask you why I see this square in red color just in my local xampp installation. If I run the code in the remote server (http://www.arreglaordenador.com/numberimage2.php) I see the
Will this protect from mysql injection?
I do not want anything like DROP TABLE to work or any type of coding.. Heres my code.. is it secure? if not, please help:Code:
array_combine() trouble w/csv file
I have a problem with a piece of code I wrote to import some records from a csv file into mysql. I have a .csv file with about 300 records in it. The code worked perfect while testing on 3 or 4
Removing Title From database problem
Hi again ! i am having an issue with updating database. When i update any price of a title it remove the title from database please can somebody help me what i am missing in my code. here it is:Code:
Stuck with preg_replace
Hi,I'm trying to use preg_replace to remove part of the IP address submitted using a form on my website. The full IP is entered into my SQL database, but when printing it on the website I want to
cURL error
So here is my code... I got it off of here... http://www.youtube.com/watch?v=XcgQUsorF_8Because I'm completely new to cURL, just wanna get a page that requires a login... I wrote everything word for
get url?
how do i get the url of the page i'm currently on, on my website.. i think its get header.. how do i do that?