Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8222287
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T14:13:32+00:00 2026-06-07T14:13:32+00:00

I have a small validation to do in my view,i have to check whether

  • 0

I have a small validation to do in my view,i have to check whether the data received from the data field (for which’null’=true) of the form is null or not.
Presently i did this by

if data_received == None :
                    "some task"

and i got what i wanted.
My question is
Is this code optimum or there is some better way to do the same.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T14:13:34+00:00Added an answer on June 7, 2026 at 2:13 pm

    That’s pretty much as good as it’s going to get. You typically want to use is None instead of == None just in case the left hand side is an instance of a class which has defined == to mean something special when used with None, but it’s not a big deal here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a small form which needs validation summary, but this validation summary should
I have a small jQuery plugin that I use for form AJAX validation. There
I have a small web form that user will enter some patient data and
I have a small form for setting event reminders. Couple check boxes and some
I have small script in bash, which is generating graphs via gnuplot. Everything works
I have done some small validation myself and end up with either - myvalid
I have built a small app using javascript. I am using javascript for form
I have a small form in Zend Framework, and when it's sent and valid,
I have a registration form which displays a users Name (textbox), Email (textbox) and
I have a small app where the index page is a form that instructs

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.