landavia
-
Posts
140 -
Joined
-
Last visited
Never
Posts posted by landavia
-
-
perhaps this might help you
$_FILES['nameoffile'][$i]['name']
$i are int???
-
???
mysql_connect ( [string server [, string username [, string password [, bool new_link [, int client_flags]]]]] )
theres no db in it!!
<?php $db_dbase="nwmarria_customers"; $db_host="localhost"; $db_pass="password"; $db_user="nwmarria_dbuser"; if (isset($_POST['submit'])) { $first_name = $_POST['firstname']; $last_name = $_POST['lastname']; $email = $_POST['email']; $output_form = 'no'; if (empty($first_name) || empty($last_name) || empty($email)) { // We know at least one of the input fields is blank echo 'Please fill out all of the email information.<br />'; $output_form = 'yes'; } } else { $output_form = 'yes'; } if (!empty($first_name) && !empty($last_name) && !empty($email)) { $dbc = mysql_connect($db_host,$db_user,$db_pass) or die('Error connecting to MySQL server.'); $db_selected = mysql_select_db($db_dbase, $dbc ); if (!$db_selected) { die ('Can\'t use foo : ' . mysql_error()); } ?>
4 u concern try type $dbname.. is better than $db_dbase
-
u need a script to build a same table.. sry.. late respondHow can I catch the name field of table1 and make it correspond with table2 name? ???
hmm.. u should try it out..
after build table2.. then copy to table 2
plzz.. remind to backup DB
*is happen 2 me AGAIN
-
<?php $stringofletters = "abcdefghijklmnopqrstuvwxyz"; $letters = array(); for ($i = 1; $i <= strlen($stringofletters); $i ++) { $letters[$i] = $stringofletters[$i]; #This is where the problem is } ?>
do you happen VB programer before done PHP?
-
using if will be better
hmm.. i take from
while ($row = mysql_fetch_array($result)) { print "<tr> <td width=\"30\" valign=\"middle\"><img src=\"images/notepad.png\" width=\"23\" height=\"18\" /></td> <td valign=\"bottom\"><li class=\"category\"><strong><a href=\"sub.php?category_id=$row[id]&cat_name=$row[category]\">$row[category]</a></strong><br><span class=\"sub\">$row[sub]</span></li></td> </tr>"; }
<?php $i=0; print "<tr>"; while ($row = mysql_fetch_array($result)) { print "\n<td width=\"30\" valign=\"middle\"><img src=\"images/notepad.png\" width=\"23\" height=\"18\" /></td> <td valign=\"bottom\"><li class=\"category\"><strong><a href=\"sub.php?category_id=$row[id]&cat_name=$row[category]\">$row[category]</a></strong><br><span class=\"sub\">$row[sub]</span></li></td>"; $i++; if($i%2==0) print "</tr><tr>"; } print '</tr>'; ?>
-
don't use extension PDF?
try other extension but not pdf?
-
and.. stay in touch in this forum make you learn php too
-
>>$sql = "SELECT * FROM `comments` WHERE comto = '$username'";
i believe the main problem in here
try
<?php echo "view comment from $username<hr/>"; $sql = "SELECT * FROM `comments` WHERE comto = '$username'"; $query = mysql_query($sql); while ($row = mysql_fetch_assoc($query)) { $from = $row['comfrom']; $message = $row['commen']; print_r($row);echo "<br/>\n"; print("$message"); } ?>
if this goes well.. perhaps..
>><? $_SERVER['PHP_SELF']; ?>
i think something missing here?
>>id="$comfrom"
about this id.. better give name that's not use $ in the front
>>mysql_query($sql) or die(mysql_error());
change this into
<?php $con=mysql_query($sql) or die(mysql_error()); ?>
i think the problem (query) not show.
suggestion:
if you want advance php. try remember this. to test script.. u must give FALSE input.. and then have error message in it. well.. you done a pretty damn good script but nobody perfect
-
sry.. i mean that problem will have problem on IE
and yeah.. that's bastard IE.. i wonder is related to SP 2?
-
hmmm.. let me guest
u put this script on
c:\phpdoc\myscript\script.php
and the folder (files) on
c:\phpdoc\files\
???
-
this is complicated JS
well...
how about add var
before
var newInput = document.createElement('input');
then
var newInput; newInput = document.createElement('input');
and i was think this
obj.parentNode.replaceChild(newInput,obj);
perhaps the problem?
-
what inside the folder
is there a file name
.httaccess?
-
premiso: thx
use premiso answer..
-
>>but for me i cant able to get that user mail id, if any possible way please tel me friends
sry.. i mixed up here
u said about to get user mail id? but i don't see any in your page contain script to save user mail id?
-
>>$atext
lets back to top post
u type like this
>>Text: <br><input type="text" name="atext[]">
and then u try to take $atext like this
>>$atext=$_POST["atext"];
this is false?!! why.. because in the first u type name as array
>> name="atext[]"
fix $atext like this
<b>$atext=$_POST["atext"][];</b>
-
this script aren't should use AJAX.. well..
to be honest
if (mail($to, $subject, $body)) { echo("Message successfully sent!"); } else { echo("Message delivery failed..."); }
in my own script.. this are failed ???
but when i type this
$stat=mail($mailto,$mailsbj,$mailmsg, $headers);
it work?
-
>>How to find whether the table is corrupt or not..
u can't.. but something like that.. (fail select).. related to crash data
>>I am using the storage engine "MYISAM"..
actualy.. type don't related to the table corrupt or not
i have DB using MYISAM.. is already fail after a year, but there more old.. not crash.. is only a matter of luck i believe
-
interesting.. but the result for TS are confuse usforumnz did you ever get this to work for you. I have the same script and am having problems with the second list.
i think the problem are the place you put your script
in my ajax (same problem).. I put 3 div (this div was the place where list will be).. hmm.. it's kinda hard to explain
<div name=text1>/*my 1st list goes here */<div> <div name=text2>/*my 2st list goes here, the 1st list are selecter */<div> <div name=text3>/*my 3rd list goes here, where 2nd list already selected */<div>
sry.. not much to help
you should try this example
there 3 list = A, B, C
A is Nation like Washington DC, California etc
B is name of City
C is name of street
-
theres no query that able to move table
CREATE TABLE `bintaro_medrec`.`terkini` ( `ID` int( 5 ) NOT NULL AUTO_INCREMENT , `KATEGORI` int( 1 ) default NULL , `HARI` varchar( 6 ) default NULL , `TANGGAL` varchar( 20 ) default NULL , `KOTA` varchar( 30 ) default NULL , `JUDUL` varchar( 200 ) default NULL , `ABSTRAK` varchar( 250 ) default NULL , `IMAGE1` varchar( 50 ) default NULL , `IMAGE2` varchar( 50 ) default NULL , `EXPIRE` int( 1 ) NOT NULL default '0', `CONTENT` text, PRIMARY KEY ( `ID` ) , UNIQUE KEY `id` ( `ID` ) , KEY `id_2` ( `ID` ) , KEY `expire` ( `EXPIRE` ) , KEY `EXPIRE_2` ( `EXPIRE` ) ) ENGINE = MYISAM DEFAULT CHARSET = latin1 AUTO_INCREMENT =99; INSERT INTO `bintaro_medrec`.`terkini` SELECT * FROM `bintaro_backup`.`terkini` ; DROP TABLE `bintaro_backup`.`terkini` ;
try copy this script
1. copy all data from table1 to table2
2. drop table 1.
3. check.. if any of the process error
-
it seem your table are corrupt
i would suggest you to repair.. but before worse happen.. try copy your table 1st then repair the table.. better create backup or lost data.
-
imho phpsensei and lostprophetpunk answer same like i want to say
but plz.. we don't understand what do you want!? please describe
1. what table do you want to search?
2. is this ALL table on 1 database or just 1 table?
3. in 1st u said Data exist (mean data inside table) but next you said rows (rows name maybe?).. where the correct?
-
that's not simple like you type on your topic
oh well.. plz change this title into SOLVED
-
nah.. i just remove that echo
about the semicolon..
i'm not remove because he/she might not type 1 query but more.. and the semicolon are needed
-
yap but noAre you getting an error message?
nope it does the echo and there is no data in the actuall DB i think it could be because i took out the WHERE section out of the query ?
reading for your sql query.. imho... that query will change EVERYTHING in your table settings into what u update
forexample.. it there 4 rows.. ALL 4 rows will change all
i kinda curios about this
<?php if(isset($_POST['submit'])) { $footer = strip_tags(mysql_real_escape_string($_POST['footer'])); $header = strip_tags(mysql_real_escape_string($_POST['header'])); $title = strip_tags(mysql_real_escape_string($_POST['title'])); $sql = "UPDATE settings SET footer = '$footer', header = '$header', title = '$title'"; mysql_query($sql) or die(mysql_error()); echo ("Update Complete"); exit; } ?>
can you change
like this
<?php print_r($_POST); //hmm i wan't to know what in this? if(isset($_POST)) { $footer = strip_tags(mysql_real_escape_string($_POST['footer'])); $header = strip_tags(mysql_real_escape_string($_POST['header'])); $title = strip_tags(mysql_real_escape_string($_POST['title'])); $sql = "UPDATE settings SET footer = '$footer', header = '$header', title = '$title'"; mysql_query($sql) or die(mysql_error()); echo ("Update Complete"); exit; } ?>
>>If there is no data in the table, what exactly is it supposed to be updating?
i assume there a data inside ^^
your answer are correct too ^^
Error message help, please
in PHP Coding Help
Posted
is there your own hosting or not?
if there is your own host.. find dir/folder name install and delete it