Search Results

Search found 443 results on 18 pages for 'validates uniqueness of'.

Page 6/18 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • C# regex to validate "realistic" IP values

    - by Joshua
    Regex that somewhat validates if a value has one of the following characteristics: 123-29-123-123.subdomain.zomg.com:8085 123.12.34.56:420 Unfortunately, I'm terrible at Regex, C#, google searches, and the differences between proper nouns and regular ones. It can be a lose approximation, in fact I would go with anything that has a : colon separator with a port after it.

    Read the article

  • I need a RegEx to validate not "NONE"

    - by Justin808
    I have a text field and am looking to have if be valid for all values other than "NONE" without the quotes. I know a comparison would be easy but the system I am using only validates via RegEx expressions. What would the RegEx expression be for it?

    Read the article

  • Regular expression to match maximium of five words.

    - by KhanS
    I have a regular expression ^[a-zA-Z+#-.0-9]{1,5}$ which validates that the word contains alpha-numeric characters and few special characters and length should not be more than 5 characters. How do I make this regular expression to accept a maximum of five words matching the above regular expression.

    Read the article

  • Some nav buttons working, others not

    - by boz
    the buttons within my submenue movie clip don't work. the one's not within a submenu work fine. my code validates and i'm not getting any errors any idea on what else i should be checking? ///this one doesn't work//// aboutSub.bio.addEventListener(MouseEvent.CLICK, goBio); function goBio(evtObj:MouseEvent) { gotoAndStop("bio"); } /// this one works//// home.addEventListener(MouseEvent.CLICK, gohome); function gohome(evtObj:MouseEvent) { gotoAndStop("home"); }

    Read the article

  • What's wrong with my JSON?

    - by Ronald
    Anybody out there notice anything wrong with this JSON? It validates at JSONLint.com, but neither Chrome nor Firefox's native JSON parse functions will properly parse it. Any ideas? { "result": "{\"players\":[{\"name\":\"User 522\",\"turn\":true,\"score\":0},{\"name\":\"User 925\",\"turn\":false,\"score\":5}],\"enableControls\":false}", "error": "null", "id": "7" }

    Read the article

  • "Can't mass-assign protected attributes" with nested protected models

    - by JohnnyFive
    I'm having a hell of a time trying to get this nested model working. I've tried all manner of pluralization/singular, removing the attr_accessible altogether, and who knows what else. restaurant.rb: # == RESTAURANT MODEL # # Table name: restaurants # # id :integer not null, primary key # name :string(255) # created_at :datetime not null # updated_at :datetime not null # class Restaurant < ActiveRecord::Base attr_accessible :name, :job_attributes has_many :jobs has_many :users, :through => :jobs has_many :positions accepts_nested_attributes_for :jobs, :allow_destroy => true validates :name, presence: true end job.rb: # == JOB MODEL # # Table name: jobs # # id :integer not null, primary key # restaurant_id :integer # shortname :string(255) # user_id :integer # created_at :datetime not null # updated_at :datetime not null # class Job < ActiveRecord::Base attr_accessible :restaurant_id, :shortname, :user_id belongs_to :user belongs_to :restaurant has_many :shifts validates :name, presence: false end restaurants_controller.rb: class RestaurantsController < ApplicationController before_filter :logged_in, only: [:new_restaurant] def new @restaurant = Restaurant.new @user = current_user end def create @restaurant = Restaurant.new(params[:restaurant]) if @restaurant.save flash[:success] = "Restaurant created." redirect_to welcome_path end end end new.html.erb: <% provide(:title, 'Restaurant') %> <%= form_for @restaurant do |f| %> <%= render 'shared/error_messages' %> <%= f.label "Restaurant Name" %> <%= f.text_field :name %> <%= f.fields_for :job do |child_f| %> <%= child_f.label "Nickname" %> <%= child_f.text_field :shortname %> <% end %> <%= f.submit "Done", class: "btn btn-large btn-primary" %> <% end %> Output Parameters: {"utf8"=>"?", "authenticity_token"=>"DjYvwkJeUhO06ds7bqshHsctS1M/Dth08rLlP2yQ7O0=", "restaurant"=>{"name"=>"The Pink Door", "job"=>{"shortname"=>"PD"}}, "commit"=>"Done"} The error i'm receiving is: ActiveModel::MassAssignmentSecurity::Error in RestaurantsController#create Cant mass-assign protected attributes: job Rails.root: /home/johnnyfive/Dropbox/Projects/sa Application Trace | Framework Trace | Full Trace app/controllers/restaurants_controller.rb:11:in `new' app/controllers/restaurants_controller.rb:11:in `create' Anyone have ANY clue how to get this to work? Thanks!

    Read the article

  • How to insert Flash without JavaScript in the most compatible but valid way?

    - by Andreas Gohr
    I'm looking for a way to embed Flash into a XHTML Transitional page that does not rely on enabled JavaScript, which validates and that works across all major Browsers including IE6. So far I'm using this solution which seems to work just fine: http://latrine.dgx.cz/how-to-correctly-insert-a-flash-into-xhtml#toc-final-solution However, when this method is used in an RSS Feed it seems that Feedburner and Google Reader at least (maybe other feed readers, too) strip the whole object tags and only leave the alternative content. Any suggestions how to improve this?

    Read the article

  • Two Phase Commit with MongoDB

    - by mattcodes
    Heres what Im thinking. Do you see any issues with this workaround to emulate 2 phase commit when using something like MongoDB where each operation is atomic and there is no support for transactions outside of that? transaction_scope: read message from servicebus - UpdateCustomerAddress get customer aggregate from docdb, replay events where commited =1 call customer.updateAddress validates creates customer address updated event apply event event store as uncommitted events do optimistic concurrency update against docdb pushing uncommitted events (single op to ensure consistency) publish event to service bus update docdb set events just published to commited = 1 (again one 1 op - at least in mongodb) transaction_complete

    Read the article

  • New Facebook like button HTML validation

    - by Eric Di Bari
    After adding the new facebook like button to my page, it no longer validates using XHTML strict. The two errors I come across are: All of the "meta property" tags say that "there is no attribute "property"" All of the variables used in the like button line are listed that there are no attributes for it. The line is as follows: <fb:like href="http://www.pampamanta.org" layout="button_count" show_faces="false" width="120" action="like" font="arial" colorscheme="light"></fb:like>

    Read the article

  • embed tag for flash and w3c

    - by drav
    when validating a site using w3c validator it tells me the tag is not valid markup. So i take it out and it works on safari/chrome but not firefox(3.5.x) but validates fine. Is there something in the tag i must add in order for firefox to display flash.

    Read the article

  • jquery group validator plugin overriding the first items

    - by christian
    SO Question: jQuery Validate - require at least one field in a group to be filled I uses the sample rule from the above link and it works, but the problem was it overrides the fields that going to be validated it jumps directly to the group validation, when validates a form the messages in my error container only contains error for the group fields.

    Read the article

  • Regular expression required

    - by KhanS
    I have a regular expression "^[a-zA-Z+#-.0-9]{1,5}$" which validates that the word contains alpha-numeric characters and few special characters and length sould not be more than 5 characters. How do I make this regular expression to accept a maximum of five words matching the above regular expression.

    Read the article

  • Chrome messes up the website layout, FF and IE is good

    - by Luuk
    I am working on a website: http://www.bbp.nl/luuk-test/wac It displays really well on FF and IE. I went tot test it in chrome and it is totally messed up. Somehow chrome displays all the divs underneath each other. I really dont know where to look since it also validates well in W3C validator. Also googled it, but could not find anything. Does anyone knows the answer? Please help.

    Read the article

  • Thin Web Services Tier

    - by Lici
    Hi folks, currently i'm working on exposing some solr queries via web services . The behavior should be the following: Client makes a request: http://api.mysite.com/hottestNews?apiKey=XXX The ws tier validates apiKey ... some aditional stuff ws tier redirects the request to : someFinder:8080/solr/select/qt=hottestNews The response is brought to client Can restlet framework help me? Thx

    Read the article

  • Validate HTML entities in JavaScript

    - by Eduard Luca
    I have a small JavaScript validation script that validates inputs based on Regex. I want to allow certain characters that are not exactly common (not sure if they're UTF8). For example I want to allow the following character ’, which looks like a single quote, but isn't. I got the HTML code for this which is &#8217;, but I'm not sure how to put this into the Regex. I've tried just inputting [&#8217]* but it doesn't validate.

    Read the article

  • security issue on web application using firebug

    - by Suresh S
    Guys i have developed a web application in jsp . I have many javscript validation for text validation in the jsp page.while during the testing , i enabled firebug in firefox and cleared a function that validates and submits to a servlet.The web application allows to submit garbage value of the textfiedl . how to overcome this ? any solutions?

    Read the article

  • Is it abuse to put application/business logic inside of jQuery plugins?

    - by RenderIn
    Is it appropriate to create jQuery plugins which are specific to a single page? I've been creating generic plugins that are not tied to any context and contain no business logic, but some people I've talked to suggest that almost all javascript, including business logic and logic specific to a single page, should be inside of jQuery plugins. Is it appropriate to have a validateformXYZ plugin which validates a specific HTML form? I'm buying into jQuery 100% but am not sure if this is a misuse or not.

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >