Forum: JavaScript / DHTML / AJAX 9 Hours Ago |
| Replies: 2 Views: 93 If you have that code on a php page then it will try to call the function and insert the output directly into that string. You have to understand the difference between a server-side language and a... |
Forum: JavaScript / DHTML / AJAX 1 Day Ago |
| Replies: 2 Views: 160 You forgot the grouping parens
somestring.replace(/(^\s*|\s*$)/g, "") |
Forum: PHP 5 Days Ago |
| Replies: 10 Views: 325 Also put
ini_set('display_errors', 'On');
Below error_reporting(E_ALL);
If you still don't see any errors it could be because you're trying to call a function which obviously does not exist... |
Forum: PHP 5 Days Ago |
| Replies: 10 Views: 325 After you placed that in the code refresh the page. Instead of a white page you should see errors. If you get errors that mention something about a MySQL result resource follow the FAQ. If it is a... |
Forum: PHP 5 Days Ago |
| Replies: 10 Views: 325 Right below # BEGIN SCRIPT place
error_reporting(E_ALL); Then follow the FAQ on the main page of the PHP forums |
Forum: PHP 5 Days Ago |
| Replies: 10 Views: 325 Show us the source of the page |
Forum: PHP 5 Days Ago |
| Replies: 10 Views: 325 Just go to the page in the browser, the same way you would locally except replace localhost with the domain name. |
Forum: PHP 7 Days Ago |
| Replies: 2 Views: 191 You haven't shown any code so the best I can do is give a short example:
class someClassA
{
public function someMethodA()
{
throw new Exception("Error");
}
} |
Forum: JavaScript / DHTML / AJAX 8 Days Ago |
| Replies: 3 Views: 320 I think I understand what you were trying to say:
var ids = [];
$('#rightList > li').each(function(el) {
ids.push(el.id);
}); |
Forum: JavaScript / DHTML / AJAX 11 Days Ago |
| Replies: 4 Views: 346 Just remove the surrounding click event ie.,
$(".run").click(function(){ ... }); |
Forum: PHP 13 Days Ago |
| Replies: 5 Views: 226 Ahh, add a space before your WHERE, right now you have SELECT * FROM myTableWHERE... |
Forum: PHP 13 Days Ago |
| Replies: 5 Views: 226 Try "WHERE ho_uniqueid='".$_SESSION['uid']."'"; |
Forum: MySQL 33 Days Ago |
| Replies: 5 Views: 493 Evn f ur prfsnal u nd 2 shw efrt. <--- This is hard to read
Even if you're a professional you need to show effort before we help you. |
Forum: MySQL 33 Days Ago |
| Replies: 5 Views: 493 I'm gonna go head and say no. (http://www.daniweb.com/forums/announcement8-2.html) |
Forum: PHP 34 Days Ago |
| Replies: 4 Views: 264 Exactly, like I said. You would have one file say image.php generate the image and in the file you wanted to show the image you'd do
<img src="image.php?someparam=somevalue" /> |
Forum: PHP 34 Days Ago |
| Replies: 4 Views: 264 If you want to place it dynamically inside another page you would have one PHP file generate the image and then point to that in an <img> tag.
But to set the content-type just use:... |
Forum: PHP Nov 18th, 2009 |
| Replies: 15 Views: 444 What he said, it's been a long day :) |
Forum: PHP Nov 17th, 2009 |
| Replies: 15 Views: 444 Remove [] from the name of the field, PHP sees that and tries to turn it into an array. |
Forum: PHP Nov 17th, 2009 |
| Replies: 2 Views: 259 time BETWEEN '$endDateTime' AND '$startDateTime' Put quotes around the dates |
Forum: HTML and CSS Nov 16th, 2009 |
| Replies: 6 Views: 531 ul#navigation {
position: fixed;
top: 10px;
left: 10px;
}
/* place the ul with the ID navigation 10px from the top-left corner of the screen */ |
Forum: HTML and CSS Nov 16th, 2009 |
| Replies: 6 Views: 531 When you use position:fixed you have to use the left and top CSS properties to position it on the page. |
Forum: HTML and CSS Nov 16th, 2009 |
| Replies: 6 Views: 531 Use position:fixed which will keep the element in the same place on the screen even if the user scrolls the page. Also, Java != Javascript |
Forum: HTML and CSS Nov 16th, 2009 |
| Replies: 4 Views: 499 You could use a <span> tag or (this may not be cross-browser compatible) you can use the first-line pseudo-selector on the div like so
div#someID { font-size: 1.8em; }
div#someID:first-line {... |
Forum: PHP Nov 13th, 2009 |
| Replies: 3 Views: 251 Your first place you should go for any question related to PHP is the PHP documentation: http://php.net/for |
Forum: Computer Science Nov 6th, 2009 |
| Replies: 9 Views: 458 There's nothing in that one, but this seems to be missing some vowels, consonants and words in general.
Google is your friend, along with Wikipedia or essentially anything that exists that... |
Forum: JavaScript / DHTML / AJAX Nov 3rd, 2009 |
| Replies: 1 Views: 423 Inside the function basicAjaxSwitch you are defining a variable basicAjaxSwitch so it's being overwritten. Just use a different variable name inside the function. |
Forum: PHP Oct 22nd, 2009 |
| Replies: 2 Views: 228 What do you mean by calling the table? Also, why're you using PDO for the connection then just completely ignoring it and using mysql_query anyway? http://php.net/pdo |
Forum: PHP Oct 20th, 2009 |
| Replies: 6 Views: 322 If you see absolutely nothing then you may be getting an error. On the line before $source = ... put ini_set('display_errors', 'On'); error_reporting(E_ALL); If you're getting an error that will show... |
Forum: PHP Oct 20th, 2009 |
| Replies: 6 Views: 322 If the file is on the same server as the script then use the absolute path. If it's a remote file use the URL. |
Forum: PHP Oct 20th, 2009 |
| Replies: 6 Views: 322 You're not giving a full path, you're giving a web path. In the first example it is making a web request to fetch the file, in the second example it is directly accessing the filesystem. Make sure... |
Forum: PHP Oct 20th, 2009 |
| Replies: 7 Views: 286 If you want to save simulations for future use just use a damn database. Don't try to go against the grain when working with PHP. There are plenty of tools as your disposal for working with stuff... |
Forum: PHP Oct 20th, 2009 |
| Replies: 7 Views: 286 You can't, use a database. It's that simple. |
Forum: PHP Oct 19th, 2009 |
| Replies: 4 Views: 238 As for this, if you're just using it as a learning experience then it should be just that. It's not a very good learning experience if you just follow someone else's tutorial. The point of recreating... |
Forum: PHP Oct 19th, 2009 |
| Replies: 4 Views: 238 If you're trying to get the value of $id in that string then you have to concatenate because you're using single quotes.
echo '<a href="profile.php?id=' . $id . '">Enzo's Profile</a>'; |
Forum: C++ Oct 14th, 2009 |
| Replies: 6 Views: 255 Based on what you needed it would make sense for the C++ app to listen (be the server) and PHP to send the data to the server (client) |
Forum: C++ Oct 14th, 2009 |
| Replies: 6 Views: 255 http://php.net/sockets
For C++ you might want to look around for forums, there's bound to be a link to a good one. If not, just google C++ sockets there is a veritable shit-ton |
Forum: C++ Oct 14th, 2009 |
| Replies: 6 Views: 255 There are a couple of ways to do it that pretty easy. If you're using the socket approach you can just have PHP open a client socket and send data to the C++ app. The other way is just to have C++... |
Forum: JavaScript / DHTML / AJAX Oct 14th, 2009 |
| Replies: 3 Views: 575 You can do something like this
<form action="delete.php or whatever" onsubmit="return confirm('Are you sure?');">
That will pop open a box that says "Are you sure?" with yes and no buttons, if... |
Forum: PHP Oct 14th, 2009 |
| Replies: 14 Views: 343 Now do the same thing, type php -v and paste the output here. If it says something like
PHP 5.2.6 (cli) (built: sometime)
Copyright (c) 1997-2009 The PHP Group
Zend Engine blah blah
Then you have... |
Forum: PHP Oct 14th, 2009 |
| Replies: 14 Views: 343 oh, hahaha, did you also do sudo apt-get install php5-cli? |