Jump to content

pngtest

Members
  • Posts

    32
  • Joined

  • Last visited

    Never

Everything posted by pngtest

  1. Thanks i will see if that helps me out.
  2. hey i was trying to fix this problem and got the error to go away by adding $_post['buscar'] but now the page just shows up blank
  3. it is on an internal network but i can describe better the header and footer are in the right place and them main container is in the right place but the left and right column are not..... all you see to the left of the screen about 5 pixel of the right column background.
  4. the columns are shifted to the left by about the whole page all you can see is the background to the right column.
  5. okay well i think there is an issue with the php cuz i have been messing around with this all day and finally made a complete html version without any php and it worked fine... can anyone help.
  6. okay i found something i would like to use but i don't think i am doing it correctly. the html code for the form is <html> <head> <title>Multibusca - PHP</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body bgcolor="#FFFFFF" text="#000000"> <small><small><font face="Verdana"> </font></small></small> <form name="form1" method="post" action="result.php" target="blank"> <table width="500" border="1"> <tr> <td> <div align="center"><font face="Verdana" size="3"><b>Multi Search PHP</b></font></div> </td> </tr> <tr> <td> <p> </p> <p><small><small><small><font face="Verdana"> <input type="text" name="palavra" size="19" style="font-size: 8pt"> </font></small></small></small> <select name="buscar" style="font-size: 7pt"> <option value="altavista">Altavista</option> <option value="aonde">Aonde</option> <option value="cade">Cade</option> <option value="google">Google</option> <option value="hotbot">HotBot</option> <option value="infoseek">InfoSeek</option> <option value="lycos">Lycos</option> <option value="radaruol">Radar UOL</option> <option value="yahoo">Yahoo !</option> <option value="zeek">Zeek</option> <option value="webcrawler">WebCrawler</option> </select> <input type="submit" value="buscar" name="buscar" style="font-size:8pt;background-color:rgb(255,255,255);color:rgb(0,0,0)"> </p> <p> </p> </td> </tr> <tr> <td><font face="Verdana" size="1">Autor: Thyago James<br> <a href="mailto:tjw@uol.com.br">tjw@uol.com.br</a> </font></td> </tr> </table> </form> </body> </html> and it links to this php <?php $urlAltavista="http://www.altavista.com/cgi-bin/query?q='".$_POST['palavra']."'&kl=XX&pg=q&Translate=on"; $urlCade="http://busca.cade.com.br/scripts/engine.exe?p1='".$_POST['palavra']."'&p2=1&p3=1&p5=10"; $urlZeek="http://busca.zeek.com.br/busca/busca.cfm?p='".$_POST['palavra']."'"; $urlYahoo="http://search.yahoo.com/bin/search?p='".$_POST['palavra']."'"; $urlHotBot="http://hotbot.lycos.com/?_v=2&RG=NA&act.search=Pesquisar&MT='".$_POST['palavra']."'"; $urlLycos="http://www.lycos.com/srch/index.html?query='".$_POST['palavra']."'&lpv=1&loc=fromlycosmain"; $urlInfoSeek="http://www.goto.com/d/search/p/go/?Partner=go_home&Keywords='".$_POST['palavra']."'&Go=Search" ; $urlWebCrawler="http://www.webcrawler.com/cgi-bin/WebQuery?searchText='".$_POST['palavra']."'"; $urlGoogle="http://www.google.com/search?q='".$_POST['palavra']."'"; $urlRadar="http://www.radaruol.com.br/index.asp?MT='".$_POST['palavra']."'&SM=MC&LG=any&DC=10&RG=.br&_v=2&act.search.x=18&act.search.y=11"; $urlAonde="http://www.aonde.com/cgi/consulta.cgi?keys='".$_POST['palavra']."'&search_type=and&I3.x=5&I3.y=10"; Switch($buscar) { Case "altavista": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlAltavista'\">"; Case "cade": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlCade'\">"; Case "zeek": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlZeek'\">"; Case "yahoo": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlYahoo'\">"; Case "hotbot": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlHotBot'\">"; Case "lycos": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlLycos'\">"; Case "infoseek": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlInfoSeek'\">"; Case "webcrawler": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlWebCrawler'\">"; Case "google": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlGoogle'\">"; Case "radaruol": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlRadar'\">"; Case "aonde": echo "<META HTTP-EQUIV='REFRESH' CONTENT=\"0; URL='$urlAonde'\">"; } ?> but whenever i try to search something i get an undefined variable for the buscar. but can't fix it.
  7. the only thing i have honestly to search web sites is this html form..... but it only searchs google for what ever is type from test.com <form method="get" action="http://www.google.com/search"> <input type="text" name="q" size="31" maxlength="255" value="" /> <input type="submit" value="Google Search" /> <input type="radio" name="sitesearch" value="" /> The Web <input type="radio" name="sitesearch" value="test.com" checked /> Ask Dave Taylor<br /> </form>
  8. figured i gave to much information just go frustrated here the the view source from fire fox. <html> <head><link href="style.css" rel="stylesheet" type="text/css"><title></title> </head> <body> <div id="maincontainer"> <div id="topsection "> <div class="innertube"> <h1>PowerNet Global</h1> </div> </div> <div id="contentwraaper"> <div id="contentcolumn"> <div class="innertube"> this should be content in the main body of the page </div> </div> </div> <div id="leftcolumn"> <div class="innertube"> <b>left column</b> <table border="0" width="180"> <tr> <td width="100%" bgcolor="#E6E6E6"><b>Support Links</b> </td> </tr> <tr> <td width="100%"><a href= "png.php?mainContent=main.html" class="menulink" class=&{ns4class};>Home</a> </td> </tr> </table> </div> </div> <div id="rightcolumn"> <div class="innertube"> news news </div> </div> <pre> <div id="footer"> <script language=JavaScript> DaysofWeek = new Array() DaysofWeek[0]="Sunday" DaysofWeek[1]="Monday" DaysofWeek[2]="Tuesday" DaysofWeek[3]="Wednesday" DaysofWeek[4]="Thursday" DaysofWeek[5]="Friday" DaysofWeek[6]="Saturday" Months = new Array() Months[0]="January" Months[1]="February" Months[2]="March" Months[3]="April" Months[4]="May" Months[5]="June" Months[6]="July" Months[7]="August" Months[8]="September" Months[9]="October" Months[10]="November" Months[11]="December" RightNow = new Date() var day = DaysofWeek[RightNow.getDay()] var date = RightNow.getDate() var Month = Months[RightNow.getMonth()] var Year = RightNow.getFullYear() if (date == 1 || date == 21 || date == 31) {ender = "<SUP>st</SUP>"} else if (date == 2 || date == 22) {ender = "<SUP>nd</SUP>"} else if (date == 3 || date == 23) {ender = "<SUP>rd</SUP>"} else {ender = "<SUP>th</SUP>"} document.write("Today is " +day+ " " +Month+ " " +date+ ender+ ", " +Year+ ".") </SCRIPT> </pre> <br></div> </div> </body> </html>
  9. yes to a database but not really how to link the search put in on my site to link to the proper site.
  10. leave this to a me to ask but i think that is my problem...
  11. I am wanting to put a search the web filed on the home page of the site i am building i used the walkthrough that was here on the site http://www.askdavetaylor.com/how_can_i_add_a_google_search_box_to_my_web_site.html but i has google search information in the site you are on and i want something where you can chose to search any one of a select few web search sites... like let them search dopile or yahoo, can anyone point me in the right direction.
  12. ok sorry notice a typo and prolly didn't give enough info... i ment php or css issue. but when you load the page there is no text and the columns are off and all shifted to the left by like 10% but if you look and what is sent to the browser it should work. as there is no error or major mistake that i can tell. i don't know if it would help but here is the source through firefox <html> <head><style type="text/css"> body{ margin: 0; padding: 0; line-height: 1.5em; } b{font-size: 110%;} em{color:red;} #maincontainer{ width: 840px; /*width of main container*/ margin: 0 auto; /*Center container on page*/ } #topsection{ background: #EAEAEA; height: 90px /*Height of top section*/ } #topsection h1{ margin: 0; padding-top: 12px; } #contentwrapper{ float: left; width: 100%; } #contentcolumn{ margin: 0 190px 0 180px; /*margins for content column. should be "0 right columnwidth 0 leftcolumn width*/ } #leftcolumn{ float: left; width: 188px; /*width of left column in pixel*/ margin-left: -840px; /*set margin to that of -(maincontainerwidth)*/ background: #C8FC98; } #rightcolumn{ float: left; width: 190px; /*width of right column in pixel*/ margin-left: -190px; /*set margin to -(rightcolumnwidth)*/ background: #336699; } #footer{ clear: left; width: 100%; background: black; color: #FFF; text-align: center; padding: 4px 0; } #footer a{ color: #FFFF80; } .innertube{ margin: 10px; /*margins for inner div inside each column (to provide padding)*/ margin-top: 0; } A.menulink{ display: block; width: 170px; text-align: left; text-decoration: none; font-family: arial; font-size: 11px; color: #000000; border: none; border: solid 1px #ffffff; } A.menulink:hover { border: solid 1px #6100c1; background-color: #f0e1ff; } </style> <title></title> </head> <body> <div id="maincontainer"> <div id="topsection "> <div class="innertube"> <h1>PowerNet Global</h1> </div> </div> <div id="contentwraaper"> <div id="contentcolumn"> <div class="innertube"> this should be content in the main body of the page </div> </div> </div> <div id="leftcolumn"> <div class="innertube"> <b>left column</b> <table border="0" width="180"> <tr> <td width="100%" bgcolor="#E6E6E6"><b>Support Links</b> </td> </tr> <tr> <td width="100%"><a href= "png.php?mainContent=main.html" class="menulink" class=&{ns4class};>Home</a> </td> </tr> </table> </div> </div> <div id="rightcolumn"> <div class="innertube"> news news </div> </div> <pre> <div id="footer"> <script language=JavaScript> DaysofWeek = new Array() DaysofWeek[0]="Sunday" DaysofWeek[1]="Monday" DaysofWeek[2]="Tuesday" DaysofWeek[3]="Wednesday" DaysofWeek[4]="Thursday" DaysofWeek[5]="Friday" DaysofWeek[6]="Saturday" Months = new Array() Months[0]="January" Months[1]="February" Months[2]="March" Months[3]="April" Months[4]="May" Months[5]="June" Months[6]="July" Months[7]="August" Months[8]="September" Months[9]="October" Months[10]="November" Months[11]="December" RightNow = new Date() var day = DaysofWeek[RightNow.getDay()] var date = RightNow.getDate() var Month = Months[RightNow.getMonth()] var Year = RightNow.getFullYear() if (date == 1 || date == 21 || date == 31) {ender = "<SUP>st</SUP>"} else if (date == 2 || date == 22) {ender = "<SUP>nd</SUP>"} else if (date == 3 || date == 23) {ender = "<SUP>rd</SUP>"} else {ender = "<SUP>th</SUP>"} document.write("Today is " +day+ " " +Month+ " " +date+ ender+ ", " +Year+ ".") </SCRIPT> </pre> <br></div> </div> </body> </html>
  13. hey not truly sure if this is a php thing or php thing but i have this css code. <style type="text/css"> body{ margin: 0; padding: 0; line-height: 1.5em; } b{font-size: 110%;} em{color:red;} #maincontainer{ width: 840px; /*width of main container*/ margin: 0 auto; /*Center container on page*/ } #topsection{ background: #EAEAEA; height: 90px /*Height of top section*/ } #topsection h1{ margin: 0; padding-top: 12px; } #contentwrapper{ float: left; width: 100%; } #contentcolumn{ margin: 0 190px 0 180px; /*margins for content column. should be "0 right columnwidth 0 leftcolumn width*/ } #leftcolumn{ float: left; width: 188px; /*width of left column in pixel*/ margin-left: -840px; /*set margin to that of -(maincontainerwidth)*/ background: #C8FC98; } #rightcolumn{ float: left; width: 190px; /*width of right column in pixel*/ margin-left: -190px; /*set margin to -(rightcolumnwidth)*/ background: #336699; } #footer{ clear: left; width: 100%; background: black; color: #FFF; text-align: center; padding: 4px 0; } #footer a{ color: #FFFF80; } .innertube{ margin: 10px; /*margins for inner div inside each column (to provide padding)*/ margin-top: 0; } A.menulink{ display: block; width: 170px; text-align: left; text-decoration: none; font-family: arial; font-size: 11px; color: #000000; border: none; border: solid 1px #ffffff; } A.menulink:hover { border: solid 1px #6100c1; background-color: #f0e1ff; } </style> and i call this with php code here <html> <head><?php include "style.css"; ?> <title></title> </head> <body> <?php echo "<div id=\"maincontainer\"> \n"; echo "<div id=\"topsection \"> \n"; echo "<div class=\"innertube\"> \n"; echo "<h1>PowerNet Global</h1> \n"; echo "</div> \n"; echo "</div> \n"; if(empty($mainContent)){ $mainContent = "main.html"; } if(empty($links)){ $links = "linktab.html"; } if(empty($news)){ $news= "newsinfo.html"; } echo "<div id=\"contentwraaper\"> \n"; echo "<div id=\"contentcolumn\"> \n"; echo "<div class=\"innertube\"> \n"; include "main.html"; echo "</div> \n"; echo "</div> \n"; echo "</div> \n"; echo "<div id=\"leftcolumn\"> \n"; echo "<div class=\"innertube\"> <b>left column</b> \n"; include "linktab.html"; echo "</div> \n"; echo "</div> \n"; echo "<div id=\"rightcolumn\"> \n"; echo "<div class=\"innertube\"> \n"; include "newinfo.html"; echo "</div> \n"; echo "</div> \n"; print <<<HERE <pre> <div id="footer"> <script language=JavaScript> DaysofWeek = new Array() DaysofWeek[0]="Sunday" DaysofWeek[1]="Monday" DaysofWeek[2]="Tuesday" DaysofWeek[3]="Wednesday" DaysofWeek[4]="Thursday" DaysofWeek[5]="Friday" DaysofWeek[6]="Saturday" Months = new Array() Months[0]="January" Months[1]="February" Months[2]="March" Months[3]="April" Months[4]="May" Months[5]="June" Months[6]="July" Months[7]="August" Months[8]="September" Months[9]="October" Months[10]="November" Months[11]="December" RightNow = new Date() var day = DaysofWeek[RightNow.getDay()] var date = RightNow.getDate() var Month = Months[RightNow.getMonth()] var Year = RightNow.getFullYear() if (date == 1 || date == 21 || date == 31) {ender = "<SUP>st</SUP>"} else if (date == 2 || date == 22) {ender = "<SUP>nd</SUP>"} else if (date == 3 || date == 23) {ender = "<SUP>rd</SUP>"} else {ender = "<SUP>th</SUP>"} document.write("Today is " +day+ " " +Month+ " " +date+ ender+ ", " +Year+ ".") </SCRIPT> </pre> <br> HERE; echo "</div> \n"; echo "</div> \n"; ?> </body> </html> but it does not look right...... the borders are off. can anyone help me.
  14. ok thanks it did not apparently i am not that good at css will have to look into that but thanks on the help guys.
  15. thanks for all of your guys help and sorry about the wierd things don't know what happened..... ok it is still not working and i still don't know why.Here is the php code. <html> <head><title></title> <body> <?php include ("pngstyle.css"); if (empty($linkMenu)){ $linkMenu = "menu.html"; }// end if if (empty($topMenu)){ $topMenu = "navigation.html"; } //end if if (empty($mainMenu)){ $mainMenu = "main.html"; } //end if print "<span class = \" linkMenu\"> \n"; include ($linkMenu); print "</span> \n"; print "<span class = \" topMenu\"> \n"; include ($topMenu); print "</span> \n"; print "<span class = \"mainMenu\"> \n"; include ($mainMenu); print "</span>"; ?> </body> <html> and the css <style type = "text/ccss"> body { background-color: red; } span.linkMenu { position: absolute; left: 1%; width: 20%; background-color: #fffff2; } span.topMenu { position: absolute; top: 2%; width: 80% background-color: #fffff2; } span.mainMenu { position: absolute; top: 6%; width: 80%; } A:link {font-color: #000000} A:hover {font-size: 10%} A:visited {font-color: #0000ff} </style> and what the source come to when you view. <html> <head><title></title> <body> <style type = "text/ccss"> body { background-color: red; } span.linkMenu { position: absolute; left: 1%; width: 20%; background-color: #fffff2; } span.topMenu { position: absolute; top: 2%; width: 80% background-color: #fffff2; } span.mainMenu { position: absolute; top: 6%; width: 80%; } A:link {font-color: #000000} A:hover {font-size: 10%} A:visited {font-color: #0000ff} </style> <span class = " linkMenu"> <ul> <li><a href = "page.php?content=main.html"> main</a> </li> </ul> </span> <span class = " topMenu"> link one </span> <span class = "mainMenu"> this should be content in the main body of the page </span> </body> <html> am i doing something wrong
  16. sorry can't copy and paste properly. <!DOCTYPE HTML PUTLIC "-//w3c//dtd html 3.2 final//en"> <html> <head> if (empty($menuPanel)){ $menuPanel = "menu.html"; } //end if if (empty($content)){ $content = "main.html"; } //end if if (empty($links)){ $links = "top.html"; } //end if print "<span class = \"topMenu\"> \n"; include ("top.html"); print "</span> \n"; print "<span class = \"menuPanel\"> \n"; include ($menu); print "</span> \n"; print "<span class = \"item\"> \n"; include ($content); print "</span> \n"; ?> </body> </html> that should be corrected.
  17. sorry guys it posted with out me finsihing typing. i need it to show a title on the top and the menu to the left and the the main in the center.
  18. Hey guys i have this code <!DOCTYPE HTML PUTLIC "-//w3c//dtd html 3.2 final//en"> <html> <head> <in.html"; } //end if if (empty($links)){ $links = "top.html"; } //end if if (empty($content)){ $content = "main.html"; } //end if if (empty($links)){ $links = "top.html"; } //end if print "<span class = \"topMenu\"> \n"; include ("top.html"); print "</span> \n"; print "<span class = \"menuPanel\"> \n"; include ($menu); print "</span> \n"; print "<span class = \"item\"> \n"; include ($content); print "</span> \n"; ?> </body> </html> that is attached to this css <style type = "text/css" body { background-color: #ffffff } span.topMenu { position: absolute; left: 30% width: 10% } h1{ color: #0000ff; font-family: "Commic Sans MS"; text-align: center } span.menuPanel { position: absolute;span.menuPanel { position: absolute; left: 15px; width: 15% background-color: #ccccff } span.item { position: absolute; border-bottom: small solid #000000; margin-left: 20%; top: 10%; right: 15%; width: 80%; background-color: #ccccff; } and i am unable to get the css working it prints the page improperly and i can not fix it everything is grouped in the left top corner
  19. yes that was a typo sorry.... but how would i fix that error i set up the table with this script if that helps $create = create table $table ( id smallint(5) NOT NULL auto_increment, username varchar(30) NOT NULL, password varchar(32)NOT NULL, PRIMARY KEY (id), UNIQUE KEY username (username) );";
  20. Hey thanks what you advised helped but i get the error could not insert data because column count does not match value count at row 1 and when i try to create a new table through php i get the error could not create table because you have an error sql syntax check the manual that corresponds to your mysql server version for the right syntax to use near 'username(username) at line 1
  21. so if i get this right i would use the way you are talking instead of the $check code that i am using. would that produce that same results or would i have to change the $qry line to get the same information.
  22. thanks as soon as i get the error i will let you know.
  23. I am creating a set of pages to establish connection to mysql. i create a page called mysqlcfg.php with this code <?php $server = 'localhost' $db_user = 'admin' $db_pass = 'admin' $database = 'test' $table = 'users' ?> and i have a log in script such as <?php include("config.php"); // connect to the mysql server $link = mysql_connect($server, $db_user, $db_pass) or die ("Could not connect to mysql because ".mysql_error()); // select the database mysql_select_db($database) or die ("Could not select database because ".mysql_error()); // check if the username is taken $check = "select id from $table where username = '".$_POST['username']."';"; $qry = mysql_query($check) or die ("Could not match data because ".mysql_error()); $num_rows = mysql_num_rows($qry); if ($num_rows != 0) { echo "Sorry, there the username $username is already taken.<br>"; echo "<a href=register.html>Try again</a>"; exit; } else { // insert the data $insert = mysql_query("insert into $table values ('NULL', '".$_POST['username']."', '".$_POST['password']."')") or die("Could not insert data because ".mysql_error()); // print a success message echo "Your user account has been created!<br>"; echo "Now you can <a href=login.html>log in</a>"; } ?> but i get an error saying that the username when some one attempts to log in does not meet the construction set in my version of Mysql or something to that nature... don't remember and a different computer. but is there anything wrong with the code or is it the way i setup the mysql database.
  24. thanks thought that might be the case.
×
×
  • 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.