SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    Nov 2012
    Posts
    52
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Lightbulb smarty php for if(this... inside a input tag

    I have a social sign-in code. When I put them inside my smarty php tpl file it give me some unclose {elseif} or {/if} error.
    I would like to know how to put "if(this..." inside smarty php or better solution.

    Code:
    	<div id="loginFm">Sign in using your registered account:<br>
    	<input type="text" name="username" {literal}onblur="if(this.value=='')this.value='Username';" onfocus="if(this.value=='Username')this.value='';"{/literal} value="Username" class="loginFm userFm">
    	</div>

  2. #2
    SitePoint Addict bronze trophy vectorialpx's Avatar
    Join Date
    Dec 2012
    Location
    Bucharest
    Posts
    247
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    The error may be from another sequence. Try to have this code as independent, without any other code.
    It looks fine to me.
    However, that's why I changed my tags from "{ }" to "[% %]"
    Be nice to nerds. Chances are you'll end up working for one - Bill Gates
    > photos | admin panel


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •