
shane85
Members-
Posts
128 -
Joined
-
Last visited
Never
Everything posted by shane85
-
hey guys...sorry I know this is the PHP section of the forums, but whenever I post anything here you guys are extremely helpful and I get an answer right away where as when I post in the HTML section of the site, I have yet to get an answer im looking for. So - im hoping someone here can help me...Also, on the computer that it wasnt displaying properly, I tried taking out the html and just putting the image link and the text itself instead of echo ticker, and it seemed to display a little better...so im wondering if the fact that its calling to php is cause the table to screw up??? this is what I posted in my post in the html forum. what is wrong with my code??? it works perfect on my computer but ive tried on a few others and it doesnt work. im giving links to 2 images - 1 on how it displays on my screen, and 2, how it displays incorrectly on others. In the 2nd image the bottom half of the bottom image is cut off because I took a screen shot and it couldnt keep the whole thing in the screen cause of the large white space in the middle that shouldnt be there. ah. the code is as follows <center> <table width="500" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="3"><img src="gfx/tv_ticker_top.jpg" width="500" height="47"></td> </tr> <tr> <td rowspan="2"><img src="gfx/tv_ticker_left.jpg" width="48" height="231"></td> <td><img src="<?php echo $_SESSION['SESS_COMPANY_LOGO']; ?>" width="406" height="216"></td> <td rowspan="2"><img src="gfx/tv_ticker_right.jpg" width="46" height="231"></td> </tr> <tr> <td height="15"><FONT color="#ffffff" size="2"> <MARQUEE bgcolor="#505050" direction="left" loop="20" scrollamount="4"><?php echo $_SESSION['SESS_TICKER'];?></MARQUEE> </FONT></td> </tr> <tr> <td colspan="3"><img src="gfx/tv_ticker_bottom.jpg" width="500" height="119"></td> </tr> </table> </center> is it because of the php in the code? how can I fix this??? the link to the image on how it SHOULD be displayed is here www.fireshock.ca/test/image1.jpg the link to the image on how it currently displays WRONG is here www.fireshock.ca/test/wrong.jpg any help is appreciated...this problem is driving me nuts and I dont know how to fix it. Thanks
-
what is wrong with my code??? it works perfect on my computer but ive tried on a few others and it doesnt work. im giving links to 2 images - 1 on how it displays on my screen, and 2, how it displays incorrectly on others. In the 2nd image the bottom half of the bottom image is cut off because I took a screen shot and it couldnt keep the whole thing in the screen cause of the large white space in the middle that shouldnt be there. ah. the code is as follows <center> <table width="500" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="3"><img src="gfx/tv_ticker_top.jpg" width="500" height="47"></td> </tr> <tr> <td rowspan="2"><img src="gfx/tv_ticker_left.jpg" width="48" height="231"></td> <td><img src="<?php echo $_SESSION['SESS_COMPANY_LOGO']; ?>" width="406" height="216"></td> <td rowspan="2"><img src="gfx/tv_ticker_right.jpg" width="46" height="231"></td> </tr> <tr> <td height="15"><FONT color="#ffffff" size="2"> <MARQUEE bgcolor="#505050" direction="left" loop="20" scrollamount="4"><?php echo $_SESSION['SESS_TICKER'];?></MARQUEE> </FONT></td> </tr> <tr> <td colspan="3"><img src="gfx/tv_ticker_bottom.jpg" width="500" height="119"></td> </tr> </table> </center> is it because of the php in the code? how can I fix this??? the link to the image on how it SHOULD be displayed is here www.fireshock.ca/test/image1.jpg the link to the image on how it currently displays WRONG is here www.fireshock.ca/test/wrong.jpg any help is appreciated...this problem is driving me nuts and I dont know how to fix it. Thanks
-
hey guys. Im very new to CSS but am quite familar with html. Im running into problems with my table not displaying correctly in different browsers so I think doing a table in CSS might be a better way to fix this problem. currently my code is as follows <center> <table width="500" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="3"><img src="../gfx/tv_ticker_top.jpg" width="500" height="47"></td> </tr> <tr> <td rowspan="2"><img src="../gfx/tv_ticker_left.jpg" width="48" height="231"></td> <td><img src="../gfx/tv_ticker_logo_worldsgym.jpg" width="406" height="216"></td> <td rowspan="2"><img src="../gfx/tv_ticker_right.jpg" width="46" height="231"></td> </tr> <tr> <td height="15"><FONT color="#ffffff" size="2"> <MARQUEE bgcolor="#505050" direction="left" loop="20" scrollamount="4" ><STRONG>This is scrolling text</STRONG></MARQUEE> </FONT></td> </tr> <tr> <td colspan="3"><img src="../gfx/tv_ticker_bottom.jpg" width="500" height="119"></td> </tr> </table> </center> u can view what im trying to accompish by viewing http://www.fireshock.ca/test/index.html the scrolling text in the page im using it for has PHP - I dont know if that makes a difference in displaying the table correctly. Viewing it in Internet Explorer and Firefox it did look a bit different (the spacing) If someone would be so kind as to help me do a CSS table showing this, I would greatly appreciate it.
-
hmmm yeah I just tried that with firefox and still there is spaccing between theupper image and lower image....but in my actualy document its really screwed up still because im using php aswell for the world gym logo, as well as the scrolling text. Could that be why?? How would I fix this?
-
yup I uploaded it here to view http://www.fireshock.ca/test/index.html
-
hey guys so on my pc, the following code <center> <table width="500" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="3"><img src="gfx/tv_ticker_top.jpg" width="500" height="47"></td> </tr> <tr> <td rowspan="2"><img src="gfx/tv_ticker_left.jpg" width="48" height="231"></td> <td><img src="<?php echo $_SESSION['SESS_COMPANY_LOGO']; ?>" width="406" height="216"></td> <td rowspan="2"><img src="gfx/tv_ticker_right.jpg" width="46" height="231"></td> </tr> <tr> <td height="15"><FONT color="#ffffff" size="+1"> <MARQUEE bgcolor="#505050" direction="left" loop="20" scrollamount="4" ><STRONG><?php echo $_SESSION['SESS_TICKER'];?></STRONG></MARQUEE> </FONT></td> </tr> <tr> <td colspan="3"><img src="gfx/tv_ticker_bottom.jpg" width="500" height="119"></td> </tr> </table> </center> displays perfectly. essentially what it is, is a tv chopped up into a few images. the top, left, right, bottom, and 2 pieces in the middle, one for a company logo, and one for a marquee with scrolling text. It displays perfectly on my pc in internet explorer, however when I try in Firefox the table displays all screwed up and images everywhere. And on older versions of internet explorer on other computers its all screwed up as well. What can I do to fix this???
-
sorry I should have said off topic in the subject....this is the only forum im a member of and thought someone could help
-
hey guys so on my pc, the following code <center> <table width="500" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="3"><img src="gfx/tv_ticker_top.jpg" width="500" height="47"></td> </tr> <tr> <td rowspan="2"><img src="gfx/tv_ticker_left.jpg" width="48" height="231"></td> <td><img src="<?php echo $_SESSION['SESS_COMPANY_LOGO']; ?>" width="406" height="216"></td> <td rowspan="2"><img src="gfx/tv_ticker_right.jpg" width="46" height="231"></td> </tr> <tr> <td height="15"><FONT color="#ffffff" size="+1"> <MARQUEE bgcolor="#505050" direction="left" loop="20" scrollamount="4" ><STRONG><?php echo $_SESSION['SESS_TICKER'];?></STRONG></MARQUEE> </FONT></td> </tr> <tr> <td colspan="3"><img src="gfx/tv_ticker_bottom.jpg" width="500" height="119"></td> </tr> </table> </center> displays perfectly. essentially what it is, is a tv chopped up into a few images. the top, left, right, bottom, and 2 pieces in the middle, one for a company logo, and one for a marquee with scrolling text. It displays perfectly on my pc in internet explorer, however when I try in Firefox the table displays all screwed up and images everywhere. And on older versions of internet explorer on other computers its all screwed up as well. What can I do to fix this???
-
how to? selecting multipe rows displaying as checkboxes?
shane85 replied to shane85's topic in PHP Coding Help
agreed. I was thinking about that today how difficult it is going to be to achieve that doing it with -....thnx for confirming that -
how to? selecting multipe rows displaying as checkboxes?
shane85 replied to shane85's topic in PHP Coding Help
im not sure??? im a newbie still learning... -
how to? selecting multipe rows displaying as checkboxes?
shane85 replied to shane85's topic in PHP Coding Help
im not sure??? im a newbie still learning... -
Only show expired records... now> $contact_next ...
shane85 replied to shane85's topic in PHP Coding Help
tried using that and it still displays all the records -
how to? selecting multipe rows displaying as checkboxes?
shane85 replied to shane85's topic in PHP Coding Help
bump -
I have a row with a timestamp using strtotime contact_next... 1 day, 2 day, 3 day etc. once that time is expired, for instance if in that row it shows 2010-04-05 and today is 2010-04-06 I want to have a button for viewing expired records. Im using the following query and switch statement to get it to orderby=expired but it isnt displaying expired records, rather just records from the contact_next field that are still good // my switch statement switch($_GET['orderby']) { case "contact_next": $orderby="contact_next"; break; case "tstamp": $orderby="tstamp"; break; case "company_name": $orderby="company_name"; break; case "city"; $orderby="city"; break; case "expired"; $orderby="contact_next"; break; default: $orderby="prospect_id"; break; } // then my query elseif ($orderby==expired) { $prospectEntries = mysql_query("SELECT *,UNIX_TIMESTAMP(tstamp) AS tstamp FROM prospects WHERE contact_next < now() ORDER BY ".mysql_real_escape_string($orderby)." ASC ".$queryLimit) or trigger_error(mysql_error()); } whats wrong?
-
hey guys, I have a field in my db called contact_date....im using strtotime from a user submitted form on when to be contact next, to it adds strtotime+1day +2 day etc etc, so it enters a time stamp in my db. What I want to do is have it so it automatically, without manually executing a script, do pretty much the following if ($arrEntry['contact_next'] == date()) { send email to $arrEntry['representative']; // subject for email here // message for email here The following prospects need to be contacted today: // dunno if need a function to print multiple entrys... put it in anyway function print_prospectEntry($arrEntry) { $arrEntry['company_name']; // show company name $arrEntry['phone']; // show company phone number $arrEntry['email']; // show email address } $prospectEntries = mysql_query('SELECT *, UNIX_TIMESTAMP(tstamp) AS tstamp FROM prospects') or trigger_error(mysql_error()); // Display prospect Entries that are = to the time stamp of today while ($prospectEntry = mysql_fetch_array($prospectEntries)) { print_prospectEntry($prospectEntry); } }
-
how to? selecting multipe rows displaying as checkboxes?
shane85 replied to shane85's topic in PHP Coding Help
hmmm im using the following code $checkboxes = array($check[0], $check[1], $check[2], $check[3]); // values for checkboxes foreach ($checkboxes as $key => $checkbox) { echo '<input type="checkbox" id="', $checkbox . $key, '" name=".$arrEntry[advertising_locations]." value="', $checkbox, '"', (in_array($checkbox, $check) ? ' checked="checked"' : ''), '>', '<label for="', $checkbox . $key, '">', $checkbox, '</label>'; } and im getting the following to happen/error Warning: in_array() [function.in-array]: Wrong datatype for second argument in edit_client.php on line 50 line 50 is (in_array($checkbox, $check) ? ' checked="checked"' : ''), '>', and its also displaying 4 chekboxes, with a > before them -
hey guys I have a table called host_locations. in this I have host_id location_name etc etc now I have a form that what im trying to do is display check boxes from the rows in this table. So for instance, say I had 4 rows in my table Java Hut Coffee Bean Joes Coffee Franks Coffe what id like to do is display these items with a checkbox next to them, so that the user in the form can select which location(s) they would like to chose, and then have this info stored into a different table which will be clients. In this table, there is a row called locations which this info needs to be stored in, I guess seperated by - so that I can do an explode statement later on to get the different locations out? My main problem is I also want to display a edit page where it will show the locations with the checkboxes checked off like they submited initially, however if they wish to uncheck one and update it, it will update the db. sorry for the long post..I posted this a few days ago which is where someone suggested $checkboxes = array('$check[0]', '$check[1]', '$check[2]', '$check[3]'); // values for your checkboxes foreach ($checkboxes as $key => $checkbox) { echo '<input type="checkbox" id="', $checkbox . $key, '" name="locations[]" value="', $checkbox, '"', (in_array($checkbox, $check) ? ' checked="checked"' : ''), '>', '<label for="', $checkbox . $key, '">', $checkbox, '</label>'; } however this doesnt work. just displays 4 checkboxes with the names $check[0] $check[1] etc beside it
-
I took out the double quotes so line 65 is as follows $prospect_id='.$_GET['prospect_id'].'; and I get the following error Parse error: syntax error, unexpected T_STRING in edit_prospect2.php on line 65
-
hmm I tried putting this in the page cause I didnt know if it was getting the variable $prospect_id="'.$_GET['prospect_id'].'"; and now I can see the prospect_id in the header, but im getting this msg Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in edit_prospect2.php on line 65...and line 65 is the above code
-
nope still not putting the prospect_id in the header..hmm....
-
subtracting 1 date field from another in mysql
shane85 replied to shane85's topic in PHP Coding Help
just tried changing it in my db to a day from yest and i doesnt display...perfect. -
subtracting 1 date field from another in mysql
shane85 replied to shane85's topic in PHP Coding Help
ignace: works perfectly! now my next question is if todays timestamp would be 2010-04-05 and I have a record that would be 2010-04-04 would it show that record as the first one? (this is in ASC order) or would it display last since the time isnt next, its already expired??? -
ahhh....I jumped the gun..... using this header("Location: edit_prospect.php?prospect_id={$arrEntry['prospect_id']}"); submits the page and gives the error, however the record for $arrEntry['prospect_id'] doesnt print in the url, so it doesnt reload that form
-
thanks alot! solved!!!
-
also, I tried changing it from prospect_id=38 to putting in the variable and I get this error Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in edit_prospect2.php on line 72 line 72 is header("location: edit_prospect.php?prospect_id=$arrEntry['prospect_id']");