Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Website Design Forum


You are currently viewing our Website Design Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Old 10-13-2004, 11:58 AM Invalid_tag_id DWMX
Novice Talker

Posts: 7
Trades: 0
I have no clue what this problem is but it has to do with the first half of my code. I have copied the same exact code form another page and pasted into the file and it gives this error in the tag inspector. It removes my opening css tag. You will notice this. If I put the < in front of the link rel tag and save it removes it. Any ideas?

BTW I am using PHP & Mysql

Thanks for any help

<?
session_start();
include("../functions.php");


$db = db_connect();


//first we check to see if we are dealing with only one item and show the form
if (!empty($_GET["id"]))
{
$query = "select * from units where ID = ".$_GET["id"];

$result = @mysql_query($query);

$row = @mysql_fetch_array($result);


$value = "<html>
<head>
<title>MUMS Major Unit Management System</title>
<meta http-equiv=\"Content-Type\" content=\"text/html\" charset=\"iso-8859-1\">
link rel=\"stylesheet\" type=\"text/css\" href=\"../main.css\">
</head>
tripwater is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 10-21-2004, 02:18 PM
labintador's Avatar
Skilled Talker

Posts: 96
Trades: 0
dwmx detected invalid tag inside a php code? If this html is inside a variable there must be something wrong the way you stored it. maybe if you can post the whole value of variable $value that would help lot in figuring out the problem.
labintador is offline
Reply With Quote
View Public Profile
 
Old 10-21-2004, 03:31 PM
Novice Talker

Posts: 7
Trades: 0
Yeah I only posted what got highlighted as invalid code when I clicked the error in the tag insoector. The funny thing is I have copied all of my code from another source that works and still get the error. I use a class and store all of my html in a var and I do this for a few reasons and have been told this is stupid because they did not understand what I am doing but here is my code: BTW Thanks for the reply


Code:
<?
session_start();
include("../functions.php");


$db		= db_connect();


//first we check to see if we are dealing with only one item and show the for
if (!empty($_GET["id"]))
	{
	$query	= "select * from units where ID = ".$_GET["id"];			
		
	$result	= @mysql_query($query);		
		
	$row	= @mysql_fetch_array($result);
	
	
	$value	= "<html>
					<head>
					<title>MUMS Major Unit Management System</title>
					<meta http-equiv=\"Content-Type\" content=\"text/html\" charset=\"iso-8859-1\">					
					link rel=\"stylesheet\" type=\"text/css\" href=\"../main.css\">
					</head>

					<SCRIPT LANGUAGE=\"JavaScript\">
					<!-- Original:  Tom Khoury (twaks@yahoo.com) -->
					<!-- This script and many more are available free online at -->
					<!-- The JavaScript Source!! http://javascript.internet.com -->

					<!-- Begin
					function placeFocus()
						{
						if (document.forms.length > 0)
							{
							var field = document.forms[0];
							for (i = 0; i < field.length; i++)
								{
								if ((field.elements[i].type == \"text\") ||
									(field.elements[i].type == \"textarea\") ||
									(field.elements[i].type.toString().charAt(0) ==\"s\"))
									{
									document.forms[0].elements[i].focus();
									break;
									}
								}
							}
						}

					//  End -->



					
				</script>

				<!--this is for our onfocus field colors-->
				<script type=\"text/javascript\" language=\"JavaScript\" src=\"../main/code.js\"></script>

				<BODY topmargin=\"0\" marginwidth=\"0\" leftmargin=\"0\" hspace=\"0\"  bgcolor=\"#ffffff\" OnLoad=\"placeFocus();\">";
			   
			   include("../main/body_header.php");

				
				
				
		$value .= "<div align=center><b><a href=../main/search_results.php?list=true>Back to results</a></b></div>
		
				<form name=units method=post action=\"../admin/unit_submit.php\">
				<table width=600 align=center border=0>
					<tr>
						<td width=50>
							Prefix 
							
							
							<input type=hidden name=id value=\"".$row["ID"]."\">
						</td>
						<td width=50>
							<input type=text size=3 maxlength=3 name=prefix value=\"".$row["Prefix"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
						<td width=110>
							Purchase Order
						</td>
						<td width=100>
							<input type=text size=8 maxlength=8 name=po value=\"".$row["PurchaseOrder"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
						<td width=50>
							Year
						</td>
						<td width=100>
							<select name=year>
							<option value=\"\"> ---";

							//here I get the current year
							$curryear	= date("Y");

							//here I go back 2 years for our starting point
							$oldyear	= $curryear - 2;

							//here I go forward 2 years for our end year
							$newyear	= $curryear + 2;

							for ($i = $oldyear; $i <= $newyear; $i++)
								{
								if ($row["Year"] == $i)
									$value .= "<option value=".$i." selected> ".$i;
								else
									$value .= "<option value=".$i."> ".$i;
					   }


		$value .= "		</select>
						</td>
						<td width=60>
							PO Line#
						</td>
						<td>
							<input type=text size=3 maxlength=5 name=line_num value=\"".$row["POLineItem"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
				</table>

				<table width=600 align=center border=0>
					<tr>
						<td width=50>
							Skew-Stock#
						</td>
						<td>
							<input type=text size=20 maxlength=15 name=skew value=\"".$row["Skew_StockNo"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
								Station/Location
							</td>
							<td>
								<select name=location>
								<option value = \"\"> -----";
								
								//here we query for all of the locations
								$query	= "select * from locations order by Loc";
								
								$result	= @mysql_query($query);
								
								for ($i = 0; $i < @mysql_num_rows($result); $i++)
									{
									$loc 	= @mysql_fetch_array($result);
									
									if ($row["LocationID"] == $loc["ID"])
										$value .= "<option value = \"".$loc["ID"]."\" selected> ".$loc["Loc"];
										
									if ($row["LocationID"] <> $loc["ID"])
										$value .= "<option value = \"".$loc["ID"]."\"> ".$loc["Loc"];		
									}
								
					$value .= "</select>
							</td>
					</tr>
					<tr>
						<td width=50>
							Serial-VIN
						</td>
						<td>
							<input type=text size=20 maxlength=20 name=serial value=\"".$row["Serial_VIN"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Model No.
						</td>
						<td>
							<input type=text size=20 maxlength=20 name=model_no value=\"".$row["ModelNo"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Color1
						</td>
						<td>
							<input type=text size=25 maxlength=25 name=color1 value=\"".$row["Color1"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Color2
						</td>
						<td>
							<input type=text size=25 maxlength=25 name=color2 value=\"".$row["Color2"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Crate No.
						</td>
						<td>
							<input type=text size=25 maxlength=25 name=crate_no value=\"".$row["CrateNo"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Section
						</td>
						<td>";
						//here we query for the section for the unit
						$query	= "select Section from section where ID = ".$row["SectionID"];
						
						$result	= @mysql_query($query);
						
						$section	= @mysql_fetch_array($result);
						
						$value .= "<input type=text size=25 maxlength=25 name=section readonly value=\"".$section["Section"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						
						&nbsp;&nbsp;&nbsp; Stack &nbsp;&nbsp;<input type=text name=bin size=4 maxlength=4 readonly value=\"".$row["Stack"]."\"  onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
					<tr>
						<td width=50>
							Description
						</td>
						<td>
							<input type=text size=40 maxlength=40 name=descr value=\"".$row["Description"]."\" onFocus=\"chgit(this)\" onBlur=\"chgback(this)\">
						</td>
					</tr>
				</table>";
				
			//here if they have the permission, we allow them the ability to modify the unit	
			if (access($HTTP_SESSION_VARS["group"],'Units Setup'))
				{
				$HTTP_SESSION_VARS["sid"] = true;
				
				$value .= "<table width=300  align=center>
							<tr>
								<td>";
								
								if ($row["Sold"] == 1)
									$value .= "<input type=checkbox name=sold checked>  Item Sold&nbsp;&nbsp;&nbsp;";
									
								else
									$value .= "<input type=checkbox name=sold>  Item Sold&nbsp;&nbsp;&nbsp;";
									
										
							$value .= "</td>
								<td align=right>
									<input type=checkbox name=delete> Delete Unit
								</td>
								<td align=right>
									<input type=submit name=submit value=\"Submit\">
								</td>
							</tr>
						</table>";
	
				}
				
				
		$value.= "</form>
					</body>
					</html>";
		
		

	}
else
	$value = "You have reached this page in error";
	

echo $value;
tripwater is offline
Reply With Quote
View Public Profile
 
Old 10-27-2004, 09:58 AM
Novice Talker

Posts: 7
Trades: 0
bump
tripwater is offline
Reply With Quote
View Public Profile
 
Old 11-04-2004, 10:19 AM
Novice Talker

Posts: 7
Trades: 0
I was asked to post my code and got no response. Can someone please help me please?

THanks
tripwater is offline
Reply With Quote
View Public Profile
 
Old 11-13-2004, 12:53 PM
Novice Talker

Posts: 7
Trades: 0
bump
tripwater is offline
Reply With Quote
View Public Profile
 
Old 11-15-2004, 02:02 PM
Novice Talker

Posts: 7
Trades: 0
bump
tripwater is offline
Reply With Quote
View Public Profile
 
Old 01-04-2005, 09:32 AM
Novice Talker

Posts: 7
Trades: 0
bump
tripwater is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Invalid_tag_id DWMX
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.27785 seconds with 12 queries