1,376 Posted Topics
Re: Try the following: [CODE]<?php $r=mysql_query('SELECT * FROM `table` ORDER BY `num` ASC') or die(mysql_error()); $prev=''; while ($row=mysql_fetch_assoc($r)) { if ($row['num']!=$prev) { echo $row['num'].' '; } echo 'G<br />'; $prev=$row['num']; } ?>[/CODE] Don't forget the replace 'num' with the column name. | |
Re: Well in your script you have forgotten to include the mysql_connect() and mysql_select_db() functions. Try adding them in at the appropriate places and also when using the php opening tag, use <?php instead of the short tag <? as some servers will not recognize the short tags. | |
Re: It's obvious isn't it. Call it "My Company" just like how your documents are in the "My Documents" directory and pictures are in the "My Pictures" directory so it makes sense to name a company "My Company". | |
Re: When posting a form using html there are two methods you may use which will alter the way you will use the php code. Inside the <form> tag you may use <form method="POST"... or <form method="GET"... Upon using them they will correspond with the following php code. [CODE]$_GET //method="GET" $_POST … | |
Re: The reality is you will need a long text list however, php does have some nice functions to make the list shorter. Say you want to match the word frank in all usernames (eg. "franky" or "dfrankzilla") then php has a function called [URL="http://au.php.net/manual/en/function.substr-count.php"]substr_count()[/URL]. If however you wish for a … | |
Re: [QUOTE=blocblue;1668004]At a guess, I assume your table `Usuarios` has more than just two columns. If so, on line 10, you need to specify the fields for which you're providing values. E.g. [CODE] INSERT INTO table_name (column1, column2, column3,...) VALUES (value1, value2, value3,...) [/CODE] If that still fails, run the query … | |
Re: [QUOTE=lvly;1663178]which version was popular before window 98?[/QUOTE] During the years >1998, there was no popular version of Windows until after Windows 98. Windows 98 was the deal breaker when Windows ME came out. The deal being why there was no popular version is that the concept of having a desktop … | |
Re: Try the following: [CODE] <!-- JAVASCRIPT TRIGGERS --> <script type="text/javascript"> $(document).ready(function(){ $("a[rel^='prettyPhoto']").prettyPhoto({ theme: 'dark_square' }); }); $.backstretch("<?php include ('banner.php'); ?>", {speed: 'slow'}); </script>[/CODE] [CODE]<?php include"db.php"; $sql=mysql_query("select * from banner where tf='1' "); $r=mysql_fetch_assoc($sql); echo 'admin/banner/images/'.$r['name']; ?>[/CODE] | |
Re: One thing I noticed in your code is line 8 of server.php which should have an ip address instead of a note saying to insert one. I don't know what the ip address is meant to be but you should read googles documentation. [CODE]$master = WebSocket("[server_IP]",12345);[/CODE] Also if there are … | |
Re: It is possible that you have invalid parameters in your .htaccess file so try following the tutorial at the following link then copy and paste the code. [URL="http://www.password-protection.com/"]http://www.password-protection.com/[/URL] If however the tutorial is hard to follow or doesn't work then you may find using cpanel or your web administrative panel … | |
This is the question that I'm curious about. How to determine if you have lived long and prospered. Does anybody have any ideas? | |
Re: Hi, When sending sms's with php, you need to sign up to an online provider and they will provide you with a php api if available for that provider. Also there is no such thing as a free sms provider as they must change you for the use of the … | |
Re: Replace line 117 with the following: [CODE]$sqlstr = "INSERT INTO static_page(judul, isi_berita)VALUES('".$judul."','".$news."')";[/CODE] | |
Re: There is the php library for sockets which is used to give the user the ability to communicate over the socket protocol just like how the curl library gives users the ability to communicate over the curl protocol. It is widely used as an alternative to curl because it works … | |
Re: So you want an allagram/conjectural where php can get a word and mix up the letters and upon request get those mixed up letters and put them back into a meaningful word. Is that correct? If so why don't you just store each word to jumbled text as being generated … | |
Re: [QUOTE=pritaeas;1664403]IF you want to save a link to the file then you must first use [URL="http://php.net/manual/en/function.move-uploaded-file.php"]this function[/URL].[/QUOTE] Indeed and the usage of that function is explained at the below tutorial. [URL="http://www.tizag.com/phpT/fileupload.php"]http://www.tizag.com/phpT/fileupload.php[/URL] | |
Re: Here is a more efficient version of your second script: [CODE] //the table.... <table border="1" align="center"> <td>Helm</td> <td>Crew</td> <td>Boat</td> <td>Sail Number</td> <?php for ($b=0;$b<$i;$b++) { echo '<td>'.($b+1).'</td>'; } //foreach($potentially as $k => $val) { echo "<td>".$k ."</td>"; } ?> <td>rsn</td> <td>points</td> </tr> <?php while ($row_seriesresults1 = mysql_fetch_assoc($seriesresults1)) { ?> <tr> … | |
Re: Use the following: [CODE]<?php $timestamp='1318245850'; if (mktime(0,0,0)<$timestamp) { echo $timestamp.' is today.'; } else { echo $timestamp.' is not today.'; }[/CODE] | |
Re: I use the following on both of my dual monitors [URL="http://www.elaph.com/elaphweb/Resources/images/Technology/2008/12/thumbnails/T_40d7219a-c291-4de8-8fd0-d157085fb3cf.gif"]internet marine cables[/URL] That way I know the quickest and least used routs for when I select a free mirror from another country. :) | |
Re: Rest In Bits Steve, Now that Steve is out of the way, there is nothing stopping Microsoft taking over Apple. ;) | |
Hi, I'm developing a new Java applet and it requires a 3d engine to import a 3d model with a texture wrapped around the model. Then the user will be able to browser around the model in like a first person shooter style but just browse/look around, nothing else. Does … | |
Re: I believe this thread belongs in the javascript/dhtml section but if you were to ask me how to solve it one thing I would mention is not to use jquery because it is not designed of the best of quality since the best of quality can only be produced from … | |
Hi, this is cwarn23 just posting a link to a youtube video for those constantly redirecting users to google or lmgtfy.com but now here is another tool for you to use. I have posted a youtube video which you can use to teach all of those users how to read … | |
Re: Replace line 53 with the following: [CODE]if (isset($confirmation)) { echo $confirmation; }[/CODE] | |
Re: [QUOTE=murnesty;1657041]Im still using c programming :D for the embedded system[/QUOTE] Yer, well while you's are learning the different variations of C I have been skimming the manuals of Assembly. Assembly is a very lengthy language but good code is lengthy unlike other languages such as c#, ruby, java, visual basic, … | |
Re: By the sounds of it, it seems like you might need a larger power supply but perhaps you should add up the wattage figures first. I know off by hand that the cpu is 130 watts. And if the VGA is 400 watts then that leaves you with 70 watts … | |
Re: Try replacing the problem line with the following: [CODE]$session = &JSession::getInstance(NULL, $options);[/CODE] When E_Notice is disabled that is the equivalent to what is set. To problem with your code is that $handler was never set a value. So I have put into getInstance an empty variables default value for you. … | |
Re: It depends how you define "remove all local NTFS permissions". If you mean to set the permissions to their default then some users may not be able to access files there were able to view before along with other files which shouldn't be viewable being viewable. That is only if … | |
Re: It usually means you have provided invalid username and password into mysql_connect(). This may be because the user does not exist or the mysql server is currently down but when in doubt copy and paste the login details you last used for another site of yours on the same server … | |
Re: I got a few: * The Cloud Mobil * Environmental Cloud Power * Clower Computing Services | |
Re: The only problem I have found when trying to search on the Daniweb forums is that the search engine embedded into the forums seems to not match relevant content. For example, on several occasions I have found a question pop up which I had answered a few years ago and … | |
Hi. I just looked at my reputation points today and found all of this negative rep. I checked the posts it came from and it appears it may be from positive upvotes which are being displayed as negative rep. Can somebody please look into this as there are all of … | |
Re: [CODE]<?php for($i=0;$i<8;$i++) include ("files/file".$i.".php"); ?>[/CODE] | |
Re: What I would suggest is download a program called LTspice and insert the circuitry into LTspice where you may perform tests to find out all of the answers. :) | |
Re: Perhaps you should [URL="http://www.google.com/"]google[/URL] for a few [URL="http://www.coursesweb.net/ajax/multiple-select-dropdown-list-ajax_t"]tutorials[/URL]. | |
Re: [CODE]<?php // start JSON decode $json = json_decode(file_get_contents('http://graph.facebook.com/131822850253006')); // define event array $event1 = array( 'id' => $json->id, 'owner_name' => $json->owner->name, 'owner_cat' => $json->owner->category, 'owner_id' => $json->owner->id, 'event_name' => $json->name, 'event_description' => $json->description, 'start_time' => $json->start_time, 'end_time' => $json->end_time, 'location' => $json->location, 'venue_street' => $json->venue->street, 'venue_city' => $json->venue->city, 'venue_state' => … | |
Re: Perhaps what you would be better off doing is when you want to append to the array, simply create a new array with the new size in its definition, then add the data from the old array to the new array and delete the old array. After that you may … | |
Re: In this instance simply delete the white spacing on lines 1 and two so delete everything before <?php on line 1 and 2. | |
Re: I think I would like to program the AI of my own robot thankyou MR Standford. | |
Re: Try the following: [CODE]mkdir("products/$id/$lastid",0777,true); mkdir("products",0777); mkdir("products/$id",0777); mkdir("products/$id/$lastid",0777);[/CODE] | |
Re: Do you mean like the following: [CODE]foreach($_POST['urls'] as $url) { foreach ($_POST['names'] as $name ) { //insert code here }}[/CODE] However be sure that $_POST['urls'] and $_POST['names'] are both arrays. | |
Re: [QUOTE=caperjack;1655870]well you cant take it apart unless you have a dust free environment to do so, the inside of the harddrive resembles a record turntable ,when you dropped it the arm with the needle hit the spinning HDD platter causing the damage ,repairable maybe but very expensive .try slaving it … | |
Re: Try the following: [CODE]<?php define('SMALL', 0); define('BIG', 1); class ClientInfo { var $flag_dirs = array(SMALL => 'assets/flags/small', BIG => 'assets/flags/big'); var $flag_ext = 'png'; function getctrybycode($code) { $countryArray = array(); $input = "includes/countries.dat"; $fd = fopen($input,"r") or die("Error: cannot open $input!"); while ($buffer = fgets($fd,4096)) { $buffer = preg_replace("/\n/","",$buffer); //chomp() … | |
I just came home and went to sign on to daniweb.com and 404 page not found. I thought WTF. I know the website exists. But now I see it is back online have you don't any changes dani? I see the "Solved:" prefix is now green but what else have … | |
Re: I would have to say Assembly, C, Python and SQL. If you can learn those four languages completely and fluently than you can solve just about any computer software issue weather it's to do with servers or linux or windows software etc. | |
Hi, as floored as the text tutorials are right now for submitting them. I thought I would put out there the idea of video tutorials. It would be exciting to see them out there. Thanks cwarn23. | |
Re: You also didn't assign the class correctly. Try replacing with the following. [CODE]$user=new Connect(); //add the two brackets[/CODE] | |
Re: Can somebody give me instructions on how to install and configure this on my vps? |
The End.