Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
3 votes
0 answers
53 views

Use a pattern for fields validation

I need to validate the fields of user sent by an API. All works fine but the only one problem is that I don't like the solution is not an OOP solution. In the controller I call the service created by ...
klsdskldsd's user avatar
1 vote
1 answer
104 views

Validation of uploading images and adding records to the database

I am doing a php project with the codeigniter framework. In my controller, I have a function that does the following. Uploads an image to the server Add a row to the database. The data would be ...
lightning_missile's user avatar
2 votes
3 answers
6k views

PHP form validation for name, email, and Twitter handle

Given the following input values from a form, create a method or methods to validate the input based on their requirements. Throw an exception if any data is invalid. 1.1 ...
Unbreakable's user avatar
2 votes
2 answers
176 views

Validation class

Can someone help me furnish my PHP validation class? I want to reduce its size and make it easier to use. ...
Dennis Kiptugen's user avatar
3 votes
2 answers
1k views

Pagination filtering

I want to check if there is page variable (in URL) and if it is, if it's correct - it cannot be number 1 because this is default page and it should be valid int ...
Marcin Nabiałek's user avatar
5 votes
2 answers
6k views

Validation and Form classes

I have written Validation and Form classes in PHP. Validation class allow you to define the ...
I'll-Be-Back's user avatar
5 votes
2 answers
290 views

Is this a good object oriented design for a file validator?

I'm working on a module that downloads a file saves it then validates if the file contents are valid. For simplicity lets assume that the file consists of 3 segments: Header, Body & Footer. Now ...
Songo's user avatar
  • 211
2 votes
1 answer
510 views

Validating forms data

Here is a class that I made to validate forms data. I will really appreciate any criticism and hints. ...
omeid's user avatar
  • 133