1,376 Posted Topics
Re: Although I don't know the oop equivalent the fgllowing is using the url for which column to sort by. [CODE]$this->sqlGetAllCmds = "select id,url,type,name,label from commands order by ".mysql_real_escape_string($_GET['orderby']);[/CODE] Or if you want to order by multiple columns in case of duplicate rows then the following [CODE]$this->sqlGetAllCmds = "select id,url,type,name,label from … | |
Hi and I often use daniweb on computers with an internet speed of around 2kbps to 24kbps to 64kbps and when using daniweb while on 2kbps and 24kbps compared to other sites like google and phpfreaks, daniweb takes a long time to load (~2mins). My suggestion is would it be … | |
Re: [QUOTE=kuteinheart;1127904][CODE] <?php session_start(); //rest of my code $_SESSION['Username']=$row['Username']; ?> //code on second page for the form is <td><input readonly="Username" type="text" name="Username" value="<?php session_start(); echo $_SESSION['Username']; ?>"></td> [/CODE][/QUOTE] That code is invalid and should be as follows: [CODE] <?php session_start(); //rest of my code $_SESSION['Username']=$row['Username']; ?> //code on second page for … | |
Re: [CODE]<?php $heading=array(0=>'Heading 1',1=>'heading 2'); for ($i=0;$row=mysql_fetch_assoc($result);$i++) { echo '<div style="background-color:orange;text-align:center"> <p>'.$heading[$i].'</p> </div> <div style="border:1px solid black"> <p>Content section</p> </div>'; }[/CODE] | |
Re: If this is solved than please click the solved button but if it's not then continue reading... The only 2 ways I have known php to create subdomains is 1 - by getting php to edit the apache config file which I wouldn't recommend. The second option is to create … | |
Re: Do you mean like this? [CODE]$result = mysql_query("SELECT Fieldvalue FROM kid_rsform_submission_values WHERE SubmissionId IN (SELECT SubmissionId FROM kid_rsform_submission_values WHERE FieldValue = '850830126317') LIMIT 14");[/CODE] | |
Re: I disagree. What your describing is you get a book written in french then translate it to english and have a uncopywrited work. Obviously that isn't how it works in the real world nor is it how it works in programming languages. So clearly changing it to another programing language … ![]() | |
Re: It is in the users cache and although they can press back and view the pages they can't click any links or make any changes. Then this comes to the question disabling the back button which I believe isn't possible but you never know what's possible. | |
Re: Your headers are invalid. Don't forget the function names are case sensitive. So turn HEADER() to header() like the following. [CODE]header("Expires: time()"); header("Pragma: no-cache"); header("cache-control: no-cache, no-store, must-revalidate");[/CODE] But I'm not sure about those strings inside the header though. | |
Re: It would be better to place all the data into a database and perhaps you could make a script that will insert it into the database for you. Then to display the content you just select from the database and display the contents from the database. | |
Re: That is a mixture of css and javascript. Basically you use css to make it look pretty then to make the background disappear simply use [ICODE]onclick="javascript:myfunction();"[/ICODE] Then javascript can change the css properties to make the background disappear. | |
Re: Perhaps you should become familiar with a [URL="http://www.tizag.com/phpT/forms.php"]php forms tutorial[/URL]. Because forms will be able to solve most of your problem and if you want it to make changes without the page refreshing then you will need to follow an [URL="http://www.tizag.com/ajaxTutorial/"]ajax tutorial[/URL] in addition to the forms tutorial. | |
Re: The scanned by signature is added by the virus scanner and therefore needs to be disabled by the virus scanner. So if you go into your servers virus scanner configurations you would untick the box for showing the scanned by in the signature. You would also do the same with … | |
Re: Why don't you use strip_tags like the following? [CODE]$input='input<br><b>string</b>'; strip_tags($input,'<p><br>');[/CODE] That will strip every tag except the <p> and <br> tags. I believe that is the solution to your problem... | |
Hi - it's me again. I have the following code but don't exactly know what it means or how to make the opposite code. The code I currently have is [CODE]#define rotateleft(x,n) ((x<<n) | (x>>(32-n))) #define rotateright(x,n) ((x>>n) | (x<<(32-n))) [/CODE] Then can be used like the following [CODE]a = … | |
| |
Re: Yes, all you need to do is give each row a unique id (eg number) and use [URL="http://www.tizag.com/ajaxTutorial/"]ajax[/URL] to make the php request. | |
Re: Try something like this: [CODE]<?php $line=82; //includes zero as 1. $newdata='this is a test 123'; $data=file('path/to/file.txt'); $data[$line]=$newdata."\r\n"; $data=implode($data); file_put_contents('path/to/output.txt',$data);[/CODE] | |
Re: I'm not sure how many people here would be familiar with Bank Wire but I suspect it is an api and I assume you've read the documentation. Then if there are other troubles with the api could you please post the code and any error messages so we can see … | |
Hi and I have a hex to int function but it isn't converting the hex to integers properly. Below is the code an example is the hex bb76e739 which should = 3145131833 but with the function it equals 2147483647. I heard sprintf or something like that can convert the hex … | |
Re: Try this. [CODE]<?php $a = 0; if($handle = opendir('./images/new_images')) { while(false !== ($file = readdir($handle))) { if(trim($file,"\r\n\t/\\")!= '.' && trim($file,"\r\n\t/\\")!= '..') { echo $nfile[] = $file; } } } foreach($nfile as $key => $value) { $add .= $value."\n"; $a = $a + 1; } $add1 = "[PICTURES]\n"; $INIadd = $add1 … | |
Re: According to Australian copyright laws it says you may not fame anothers website as your own unless you receive permission from the contents author. So basically if you were to embed a Flash game or webpage from another site on your site then that would be breaking the law unless … | |
Re: The best way to have a short and easy to remember password is by having a password like the following [ICODE]¢£¤¥¦§[/ICODE] or even the whole ascii table like the following [CODE] !"# $%&'()*+,-./0123 456789:;<=>?@ABC DEFGHIJKLMNOPQRS TUVWXYZ[\]^_`abc defghijklmnopqrs tuvwxyz{|}~€�‚ƒ „…†‡ˆ‰Š‹Œ�Ž��‘’“ ”•–—˜™š›œ�žŸ ¡¢£ ¤¥¦§¨©ª«¬®¯°±²³ ´µ¶·¸¹º»¼½¾¿ÀÁÂà ÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓ ÔÕÖרÙÚÛÜÝÞßàáâã äåæçèéêëìíîïðñòó ôõö÷øùúûüýþÿ[/CODE] Who … | |
Re: Do you mean like this? [CODE]<?php $clientid = mysql_real_escape_string($_GET['client']); $query = "SELECT * FROM client_details INNER JOIN users ON client_details.userID = users.id WHERE userID = $clientid"; $result = mysqli_query($dbcon,$query) or die('Error executing database query'); if (mysqli_num_rows($result) < 1) { die('Error obtaining client details, no rows found. <a href="' . $_SERVER["HTTP_REFERER"] … | |
Re: I wonder how long until they invent replicators. Replicators would be able to wipe out the robots with no problem. Or what about hackers hacking into a robot network. A hacker could send a Trojan to all robots in the United States and give those robots the command to destroy … | |
Re: Your sql string, shouldn't it be modified with a WHERE clause so it only matches one row? [QUOTE]$sql="SELECT owner_id FROM tbl_sellers";[/QUOTE] | |
Hi and I have been searching the web but my answer isn't looking very hopeful. I need javascript or preferably css to make my text vertical so the result is something like the following. [CODE]t e s t i n g[/CODE] However with the result each of the characters need … | |
Re: Do you mean like this? [CODE]<?php $variable='i45'; echo '<img src="http://'.$variable.'.expamle.com/'.urlencode($_GET['code']).'">'; ?>[/CODE] | |
Re: Do you mean [ICODE]$_POST['text1']=$_POST['text2'];[/ICODE]? | |
Re: Your right about unlimited hosting. I signed up for [URL="http://www.justhost.com/"]justhost[/URL] and although I get unlimited webspace and unlimited bandwidth I am very restricted on what content I can publish and how much traffic I can have. So people like that are just a rip off. If you are after decent … | |
Re: No. The Google OS hasn't even got the drivers for a harddrive. So basically Googles OS has 1992 technology (No hard drive and no cd rom just a flash drive) and should be put in a museum. And what is this about Googles OS can only run Crome. You cannot … | |
Re: [QUOTE=Altairzq;1120284]Hello Kyle, thanks a lot for your reply. I'm not placing my php scripts in the cgi-bin/php folder, my scripts are inside the folder structure of my website. As you say, they were executed fine anywhere in the server when I had my website in another hosting so I thought … | |
Re: Try make action="success.php" and in success.php place the following code. [CODE]$url = 'http://www.mywebsite.com/cgi-bin/cgiemail/form/form.txt'; //url-ify the data for the POST foreach($_POST as $key=>$value) { $fields_string .= $key.'='.$value.'&'; } rtrim($fields_string,'&'); //open connection $ch = curl_init(); //set the url, number of POST vars, POST data curl_setopt($ch,CURLOPT_URL,$url); curl_setopt($ch,CURLOPT_POST,count($fields)); curl_setopt($ch,CURLOPT_POSTFIELDS,$fields_string); //execute post $result = curl_exec($ch); … | |
Re: You should use the target="_Top" method. For example, below is an example of making a link. [CODE]<a href='test.php' target="_Top">test</a>[/CODE] And below are other possibilities you can try out. [CODE]<a href='test.php' target="_Blank">test</a><br> <a href='test.php' target="_New">test</a><br> <a href='test.php' target="_Self">test</a>[/CODE] | |
Re: [QUOTE]So my question is, "Does the browser have an effect on the type of a file uploaded?"[/QUOTE] Yes because if you go into the Opera preferences you will see that Opera will only recognize web related mime types. Other mime types are not programmed into Opera where as a browser … | |
Re: Is email_activated an integer field because if it is then the mysql query would be as follows. [CODE]mysql_query("SELECT * FROM `Goodisonpark` WHERE `email`='$email' AND `password`='$pass' AND `email_activated`=1");[/CODE] | |
Re: [QUOTE]At login.php, when i echo the session data that was passed it is null. Why.?[/QUOTE] Do you have cookies enabled? Also does $_POST['course'] exist? And is $_POST['course'] a radio button? You need cookies enabled for sessions to work and as for radio buttons, sometimes they will return null if no … | |
Well the first month of 2010 has almost gone in a flash. I'm sure the years shortest month February coming up will be just as good. Do you have any new months resolutions. And what did you think of January 2010 or January 2009 for those who are Chinese. | |
Re: Try this. [CODE]$count = mysql_query("SELECT * FROM qqq WHERE question = '$question' && answer = '$answer' && questionid = '$id'") or die(mysql_error()); $score = mysql_num_rows($count);[/CODE] | |
Re: [QUOTE=4789787;1117290]That didnt work... when i went to the page that you need to be logged into to view it just redirected me to login.php thanks for trying though....[/QUOTE] Have you set your browser to delete your cookies when you close your browser. I would check your cookie preferences in your … | |
Re: [QUOTE=Salem;1106333]The linked thread still barfs...[/QUOTE] Same here and when I tried to post pi to 10000 digits it also said the server was out of memory. Annoying error. | |
Re: I would suggest the following: [CODE]<?php file_get_contents('http://cronsubdomain.yoursite.com/job1.php'); file_get_contents('http://cronsubdomain.yoursite.com/job2.php'); file_get_contents('http://cronsubdomain.yoursite.com/job3.php'); file_get_contents('http://cronsubdomain.yoursite.com/job4.php'); file_get_contents('http://cronsubdomain.yoursite.com/job5.php'); file_get_contents('http://cronsubdomain.yoursite.com/job6.php'); file_get_contents('http://cronsubdomain.yoursite.com/job7.php'); ?>[/CODE] Then you will have no problems with memory limits and function definitions as they are each a separate request. | |
I have a great project and the code is done but now I need a big computer. The specs are as follows Ram: 32GB CPU: Whatever GHz Harddrive: 8TB Video: 256MB etc. but Does anybody know when the technology will be available to have 32GB of ram with a price … | |
Hi and I have been working on an image uploader but need to be able to convert tiff files using php. From my understanding there is the gd library which doesn't support tiff files and the [URL="http://au.php.net/manual/en/function.exif-thumbnail.php"]exif library[/URL]. Does anybody know how I can convert a tiff file to a … | |
Re: Generally when debugging mysql the following is how to do it. [CODE]<?php $link = mysql_connect("localhost", "uname", "pword") or die('error 1<hr>'.mysql_error()); mysql_select_db("dbname", $link) or die('error 2<hr>'.mysql_error()); $result = mysql_query("SELECT ID FROM tbl_sellers", $link) or die('error 3<hr>'.mysql_error()); $num_rows = mysql_num_rows($result); echo "$num_rows Rows\n"; ?>[/CODE] | |
Re: Try replacing your first script with the following. [CODE]<? begin_block('Donate'); echo '<BR><BR><CENTER>This would need to contain your donation code, or something. maybe even a paypal link</CENTER><BR><BR>'; echo '<a href="member.php?mid='.$row['mid'].'">$row[login]</a>'; end_block(); ?>[/CODE] Also don't forget to include the api file. | |
Re: Perhaps the following code would be of some use to you. [CODE]<?php //no html/browser output before this function header('Location: http://www.example.com/'); exit; //...[/CODE] | |
Re: [QUOTE]my problem is i dont have my own webserver so im trying to make an mp3 upload form.[/QUOTE] Then you will be in for a real treat when you get a localhost server on your own computer. I would suggest downloading [URL="http://sourceforge.net/projects/xampp/files/"]xampp 1.7.0[/URL] and install it to your computer then … | |
Re: This is a hard question which I paid good money to solve. You need to download the library(s) source (eg the GD Source) then upload the source code to your server. After that you need to compile the source into the webserver via command line and when your finished that … |
The End.