Jump to content

shaunno2007

Members
  • Posts

    40
  • Joined

  • Last visited

    Never

Everything posted by shaunno2007

  1. If the div "#accessmenu_close_hide" is clicked then i want it to do the if statement so then when it is clicked it will check if the html in the "#accessmenu_close_hide" div is "<img src="images/lock_48.png" width="20" border="0" height="20">" if it is then i want it to do the if statement if not then i want it the else statement do you no what i mean? thanks Shaun
  2. hmm okay.. what would be the best way to do this then cos am stuck lol.. thanks
  3. Okay fine in FF but I.E don't work I really do hate I.E :/ Anyway just seeing if you can help me here is the code: Code: $("#accessmenu_close_hide").click(function(){ if(document.getElementById("accessmenu_close_hide_link").innerHTML == '<img src="images/lock_48.png" width="20" border="0" height="20">') { $("#accessmenu_close_hide").animate({ marginRight: "10px" }, 0400 ); $("#accessmenu_close_hide_link").html('<img src="images/lock_open_48.png" width="20" height="20" border="0" />'); $("#accessmenu").fadeIn("normal"); }else{ $("#accessmenu_close_hide").animate({ marginRight: "-2px" }, 0400 ); $("#accessmenu_close_hide_link").html('<img src="images/lock_48.png" width="20" height="20" border="0" />'); $("#accessmenu").fadeOut("normal") }; }); Thank you Shaun
  4. This stuff is hard look at this code: How can make php echo out all my images from my server onto my website? Right, what i am trying to do is echo out the pictures that are in the server, and at the same time echo out the links, i don't know how to say it i hope you understand. What i am getting with this is it echos out the picture, but 2 times and its in all of the link (my information box thing). i hope you understand you prob will not but i will see <?php while($website_row_m_i = mysql_fetch_array($website_result_m_i)) { ?><a href="javascript:#" title="<?php echo "<center><b>Link Information Box</b></center>"; ?> <br/> <?php echo "<center><b>Link</b></center>" ; ?> <center> <?php echo substr ($website_row_m_i['url'], 0, 31); ?> </center> <br/> <?php echo "<b>From</b>: <font color='red'>{$website_row_m_i['name']}</font>" ; ?> <br/> <br/> <b>Category</b> <br/> <?php echo $website_row_m_i['category_id']; ?> <br/> <br/> <b>Description</b> <br/> <?php echo "<font size='1'>{$website_row_m_i['description']}</font>" ; ?> <br/> <br/> <b>Submitted on the:</b> <br/> <?php echo $website_row_m_i['created_at']; ?> <br/> <br/> <?PHP $folder = "uploads/"; $handle = opendir($folder); # Making an array containing the files in the current directory: while ($file = readdir($handle)) { $files[] = $file; echo "<img src='uploads/$file' /> <br />"; } closedir($handle); #echo the files ?>" style="cursor:default">More Info</a><br /> <?php } ?>
  5. http://www.boonage.pjss2.net/2007/02/12/ajaxphp-shoutbox-tutorial/
  6. i did not make this script just to say am not that good lol here is the link where i got it from http://boonage.pjss2.net/2007/02/12/ajaxphp-shoutbox-tutorial/
  7. OK check my shoutbox out at www.link-search.co.nr/shoutbox.php and as you see it has ajax all i want to do is after someone submits a shout it echos out "shout send" or something i will post the shoutbox on here.... shoutbox.php <h1>Shoutbox</h1> <div id="shoutbox"> <form id="shout" name="shoutbox" method="POST" onsubmit="saveData(); return false;"> <p>Name:<br /> <input name="shouter" type="text" class="shouter" size="10" maxlength="15" /> URL/Email: <input name="shouter_contact" type="text" class="shouter_contact" size="10" /> Comment: <input name="shouter_comment" type="text" class="shouter_comment" value="" size="16" /> <input name="submit" type="submit" class="submit" id="submit" value="submit" /> </p> </form></div> <div id="shoutarea"> </div> sendshout.php <?php include("shoutbox-connect.php"); open_connection(); $shouter=addslashes(strip_tags(htmlspecialchars($_POST['name'], ENT_QUOTES))); // Cleans Input. $shout=addslashes(strip_tags(htmlspecialchars($_POST['message'], ENT_QUOTES))); // Cleans Input. $contact=addslashes(strip_tags(htmlspecialchars($_POST['contact'], ENT_QUOTES))); // Cleans Input. $timestamp = date("Y-m-d H:i:s"); //echo $temp; $shout_sql = "INSERT into shoutbox (name, date, content, link) VALUES ('$shouter', '$timestamp', '$shout', '$contact')"; $shout_result = mysql_query($shout_sql); ?> outputinfo.php <?php header("Expires: Sat, 05 Nov 2005 00:00:00 GMT"); header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); include("shoutbox-connect.php"); open_connection(); $shout_query = "SELECT * FROM shoutbox ORDER BY `date` DESC LIMIT 0 , 15" ; $shout_result = mysql_query($shout_query); $count = 0; while($shout_row = mysql_fetch_array($shout_result)) { $shouter_name = $shout_row['name']; $shout_content = $shout_row['content']; $shout_content = stripslashes($shout_content); $shout_date = $shout_row['date']; $shouter_contact = $shout_row['link']; $contact_count = 0; $dday = substr($shout_date, 8, 2); $dmonth = substr($shout_date, 5, 2); $dyear = substr($shout_date, 0, 4); if(($count % 2) != 0) { echo "<p class='odd'><a href='http://$shouter_contact'><font color='#FFFFFF'>$shouter_name</a></font> - $shout_content <font color='#FFFFFF'>$dday-$dmonth-$dyear</font></p>"; } else { echo "<p class='even'><a href='http://$shouter_contact'><font color='#FFFFFF'>$shouter_name</a></font> - $shout_content <font color='#FFFFFF'>$dday-$dmonth-$dyear</font></p>"; } $count++; } if(isset($_POST['submit'])) { echo "Shout successfully sent"; } // as you can see here i tryed if(isset($_POST['submit'])) but i don't work ?> database-connect.php <?php $host = "localhost"; $user = "root"; $pass = ""; $db = "bizlizard"; $table = "websites"; $connect = mysql_connect($host, $user, $pass); mysql_select_db($db); ?> if there is anything i have miss then please say or if you want something else what will hellp you help me with this say thank you
  8. This part i don't understand. This part i don't understand. This oark i do understand i have done this i will show you my name for the tables field names and the database name.
  9. hmm... now i am getting this... Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\wamp\www\bizlizard\link-search.co.nr new design\index.php on line 85 Don't know why tho. Could i some how make it so it goes to another page like so... someone submits the form and then it sends the data and the user to search.php and the results are there?
  10. Got a problem... Its saying Parse error: syntax error, unexpected T_ECHO in C:\wamp\www\bizlizard\link-search.co.nr new design\index.php on line 89 I don't know why i am getting this.
  11. thanks for your reply i will have a play around with it now
  12. I have this form <form id="submit-search-query" name="submit-search-query" method="get" action=""> <label> <center><input name="search" type="text" class="show-search-box-text-box" size="20"/> </center> </label> <label> <center><input name="submit-search" type="submit" class="show-search-box-submit-button" value="Search" /> </center> </label> </form> and i want it to search my database and echo out the search results that have to word what was entered in the form. Can anyone help thanks Shaun
  13. how can i put it with this cos i have this... <?php while($website_row = mysql_fetch_array($website_result)) { ?> <a href="http://<?php echo $website_row['url']; ?>" target="_blank"><?php echo substr ($website_row['link'], 0, 76). "<br />" ; } ?></a>
  14. This is about "substr". How can i make so that ... goes on the end of my string but only if it goes over the length?
  15. Its not that i dont want people to view it in FF its because when people login to my website in FF the website goes wrong and i don't no how to fix it can you have a look and then you will no what i mean ok thanks Shaun www.link-search.x10hosting.com
  16. -------------------------------------------------------------------------------- I have seen a way this can be done but a can not remember how or where i have seen it. Like when you go onto microsoft website using FF, to download something it says you are not using IE bla bla bla. how do you check to see what browser the user is using
  17. I have seen a way this can be done but a can not remember how or where i have seen it. Like when you go onto microsoft website using FF, to download something it says you are not using IE bla bla bla. how do you check to see what browser the user is using ???
  18. What will i need to do if i want to put something on my website that checked what browser the user is using and if there are using FF recommend them to use IE or if they are using IE recommend them to use FF. I would want it to echo out something saying "You are using FF we recommend you to use IE for this page!" How could i do this? thanks Shaun
  19. If anyone knows then please put it here thanks
  20. Does anyone know how this can be done?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.