T_constant error?

Discussion in 'PHP' started by Xphic, Oct 23, 2008.

  1. #1
    
    
    <SCRIPT language="Javascript">
    var cpmstar_rnd=Math.round(Math.random()*999999);
    var cpmstar_pid=xxxx;
    document.writeln("<SCR"+"IPT language='Javascript' src='http://server.cpmstar.com/view.aspx?poolid="+cpmstar_pid+"&script=1&rnd="+cpmstar_rnd+"'></SCR"+"IPT>");
    </SCRIPT>
    
    
    HTML:

    When I ad that code it says T_constant error. Any help to find whats wrong?
     
    Xphic, Oct 23, 2008 IP
  2. Kyosys

    Kyosys Peon

    Messages:
    226
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    0
    #2
    that's not PHP
     
    Kyosys, Oct 23, 2008 IP
  3. Kaizoku

    Kaizoku Well-Known Member

    Messages:
    1,261
    Likes Received:
    20
    Best Answers:
    1
    Trophy Points:
    105
    #3
    What do you mean ad the code? What does "ad" the code mean?
     
    Kaizoku, Oct 23, 2008 IP
  4. Kyosys

    Kyosys Peon

    Messages:
    226
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    0
    #4
    "add", it's a typo, obviously
     
    Kyosys, Oct 23, 2008 IP
  5. salahsoftware

    salahsoftware Peon

    Messages:
    63
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    display that in echo along with double quote, use \" for double quotes within the double quotes.
     
    salahsoftware, Oct 23, 2008 IP
  6. Xphic

    Xphic Active Member

    Messages:
    1,323
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    80
    #6
    I still got the error for some reason, I think I may of screwed it up
     
    Xphic, Nov 5, 2008 IP
  7. keiths

    keiths Peon

    Messages:
    109
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Can you display the rest of the code?
     
    keiths, Nov 5, 2008 IP
  8. Xphic

    Xphic Active Member

    Messages:
    1,323
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    80
    #8
    It about 350 lines or something he the portion of the area

    		
    <?php
    
    // code
    
    <div class="Menu">
    			<a href="'.$image_path.'"><img src="'.$image_path.'images/Home1.png" alt="Home" onmouseout="this.src=\''.$image_path.'images/Home1.png\'" onmouseover="this.src=\''.$image_path.'images/Home2.png\'"/></a> '.$Guest_Submit.'
    		</div>
    		
    		<!-- google_ad_section_start -->
    			<div class="ContentLeft Left">
    			
    			<!-- Ads section -->
    				<div class="ContentHeader1">
    					Ad
    				</div>
    				<div class="ContentArea" align="center">
    			<SCRIPT language="Javascript">
    var cpmstar_rnd=Math.round(Math.random()*999999);
    var cpmstar_pid=xxxx;
    document.writeln("<SCR"+"IPT language='Javascript' src='http://server.cpmstar.com/view.aspx?poolid="+cpmstar_pid+"&script=1&rnd="+cpmstar_rnd+"'></SCR"+"IPT>");
    </SCRIPT>
    					
    				</div>
    			<!-- End Ads section -->
    				
    				<div class="ContentHeader1" style="margin-top: 5px;">
    					Wallpaper Categories
    				</div>
    
    //more code
    ?>
    PHP:
     
    Xphic, Nov 5, 2008 IP
  9. Bind

    Bind Peon

    Messages:
    70
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #9
    
    <div class="Menu">
    <?php
    echo '  <a href="'.$image_path.'"><img src=".'$image_pathimages.'/Home1.png" alt="Home" onmouseout="this.src=\''.$image_path.'images/Home1.png\'" onmouseover="this.src=\''.$image_path.'images/Home2.png\'"/></a> '.$Guest_Submit;
    ?>
    </div>
    <!-- google_ad_section_start -->
    <div class="ContentLeft Left">
        <!-- Ads section -->
        <div class="ContentHeader1">
        Ad
    </div>
    <div class="ContentArea" align="center">
        <SCRIPT language="Javascript">
            var cpmstar_rnd=Math.round(Math.random()*999999);
            var cpmstar_pid=xxxx;
            document.writeln("<SCR"+"IPT language='Javascript' src='http://server.cpmstar.com/view.aspx?poolid="+cpmstar_pid+"&script=1&rnd="+cpmstar_rnd+"'></SCR"+"IPT>");
        </SCRIPT>
    </div>
    <!-- End Ads section -->
    <div class="ContentHeader1" style="margin-top: 5px;">
        Wallpaper Categories
    </div>
    
    PHP:
     
    Bind, Nov 5, 2008 IP
  10. Xphic

    Xphic Active Member

    Messages:
    1,323
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    80
    #10
    Thanks bind, but it was this part...

    <SCRIPT language="Javascript">
            var cpmstar_rnd=Math.round(Math.random()*999999);
            var cpmstar_pid=xxxx;
            document.writeln("<SCR"+"IPT language='Javascript' src='http://server.cpmstar.com/view.aspx?poolid="+cpmstar_pid+"&script=1&rnd="+cpmstar_rnd+"'></SCR"+"IPT>");
        </SCRIPT>
    PHP:
    But is that all I need an echo?
     
    Xphic, Nov 5, 2008 IP