POG1
Members-
Posts
71 -
Joined
-
Last visited
Never
Everything posted by POG1
-
What you could to stop spam and poo stories is have them be accepted or rejected before they are allowed. 65,000 is good enough for a decent short story (not a novel).
-
Im stuck with ezSQL. I have decided to upgrade my old version of ezSQL and i'm having some problems with connecting to the database. It needs 2 classes included which I have done. Then when i try to connect it shows about 10 error messages. Here is the code i used; require('lib/connection.php'); // classes are in here $db = new ezSQL_mysql; $db->connect('root', '', 'localhost'); // default login settings for LAMP Any suggestions as to what I can do? Or any suggestions to a better class to use?..
-
4 things.. 1. Make them enter their email twice. 2. Show on the page if the email is valid. 3. Do a server side check to see if the email is valid. 4. You could use ajax to show if the email is taken or dHTML to check if the emails match.
-
$finish = 94438384; // timestamp of when it finishes $width = time() / $finish; if($width > 1) { $width = 1; } echo '<div id="outer">'. '<div id="inner" style="width:'.$width.'%;">'. '</div>'. '</div>'; CSS div#outer { height:10px;width:200px;background:#900;padding:0; } div#inner { height:10px;background:#090;margin:0;padding:0; }
-
If its in a frame why not just use GET?
-
Ok it didn't work would there be a better way of getting the class working with just 1 function in it?
-
Thanks for the help but i have another problem now. how can i use the functions for the db? I tried this... $this->db->qstr($id)
-
db is defined sorry, i just copy and pasted the class that isn't working. How can I get db to work inside of this class?
-
I have 2 separate classes, database and user class. Inside the user class I have to do a query and if i try to use the db class it produces an error, is there any way i can make this work? I have tried things but with no success. class User { protected $id; public function getDetails() { $this->id = (int) $_SESSION['user_id']; $query = 'SELECT `Username` FROM `' . DBPREFIX . 'users` WHERE `ID` = ' . $db->qstr ( $id ) ; // do stuff? return true; } } The error it says is "Fatal error: Call to a member function qstr()"
-
it would be a better idea to do it in JS. The page will not validate correctly with the marquee because it is now depreciated.
-
echo '<input value="'.$_REQUEST['username'].'" name="username" />'. '<select name="dropdown">'. '<option value="1" '.(($_REQUEST['dropdown'] == '1')?'selected="selected"':FALSE).'>1</option>'. '<option value="2" '.(($_REQUEST['dropdown'] == '1')?'selected="selected"':FALSE).'>2</option>'. '</select>'. '<input type="radio" name="rdo" '.(($_REQUEST['rdo'] == TRUE)?'checked="checked"':FALSE).'/>';
-
you could wrap each of those underlying rows in a div or you could just put the additional rows in an extra table. Either way you will probably have it working pretty easy.
-
You will need a JavaScript function. You could probably add it to the on click event for the image and show hide the additional data Here is a function you could use function toggle(obj) { document.getElementById(obj).style.display = (el.style.display != 'none' ? 'none' : '' ); }
-
<img src="<?php echo $nation['nation_flag']; ?>" style="float:left;" /> <img src="<?php echo $nation['nation_symbol']; ?>" style="float:right;" /> <b><u><center>Government of <?php echo $nation['nation_name']; ?></center></u></b> <br style="clear:both" />
-
[SOLVED] ERROR 1062 (23000) at line 3: Duplicate entry '3' for key 1
POG1 replied to eMonk's topic in MySQL Help
It needs to auto increment. -
\+
-
The query would have returned an error and it then triggers the error in the loop. Try changing the lino to this: $k = mysql_query("SELECT * FROM servers ORDER BY top") or die(mysql_error()); It will show what you have done wrong in the query.
-
It's because the easy news include if after the query and that is where the database connection is, try putting the connection code at the top of the page..
-
All you need to do is echo the additional values in the hidden area.
-
If you think about it, all the search engine will see is a flash object on a page so you are loosing out on SEO a lot.
-
Yahoos UI has some grids, although i would go for the php grid.
-
<?php $result = @mysql_query("SELECT `headlineFieldName` As a FROM `news` ORDER BY `id` DESC LIMIT 1;",$conn) or die('news selection error'); if(@mysql_num_rows($result)) { $newsTitle = mysql_fetch_array($result,MYSQL_ASSOC); $newsTitle = $newsTitle['a']; $title = $newsTitle . ' - Latest news from This is Dunstable'; } else { $newsTitle = 'No News - Latest news from This is Dunstable'; ?> <?xml version="1.0" encoding="utf-8" ?> <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title><?=$newsTitle?></title> <meta name="description" content="Dunstable, Bedfordshire - Information, and local resources from This is Dunstable" /> <meta name="keywords" content="dunstable, bedfordshire" /> <meta name="Robots" content="index,follow" /> <link rel="stylesheet" href="style.css" type="text/css" /> </head> <body> <div id="container"> <?php include("includes/header.shtml"); ?> <div id="menu-left"> <?php include("includes/menu.shtml"); ?> </div> <div id="content"> <h3><span class="green">this</span><span class="grey">is</span><span class="blue">news</span></h3> <?php include_once("news/easynews.php"); ?> </div> <div id="sidebar"> <?php include("includes/sidebar.shtml"); ?> </div> <div style="clear:both;"></div> </div> <div id="footer"><?php include("includes/footer.shtml"); ?></div> </body> </html>
-
You want to avoid flash because you will loose a lot of people viewing.
-
Why make 2 topics?