0

I am trying to validate uid and pwd using a Visualforce page with javascript, but I'm getting an error saying the element type <apex:pageblocksection> must be terminated by the matching end-tag. What's wrong with this code?

<apex:page>
<script>
    Function f1(Uid){
        Var u = document.getElementByid(Uid).value;
                if(u == ''){
                        alert('Please Enter User name..')
                        document.getElementbyid(uid).focus()
                    }
        }
<script>
<apex:form>        
<apex:pageblock>

<apex:pageblocksection title="Entry section..">
    <apex:outputText Value = "Enter Uid.."></apex:outputText>
    <apex:inputText id="uid"/>
        <apex:commandbutton value="Submit" onclick="f1('{!$Component.uid}')"/>
<apex:pageblocksection>
    </apex:pageblock>
</apex:from>
</apex:page>
  • 1
    Please correct the spelling </apex:from> it should be </apex:form> – Reshma May 31 '18 at 8:22
1

You're missing a forward slash on you closing tag, it should be:

  </apex:pageblocksection>
</apex:pageblock>
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.