Form Creation and Validation in Slim Framework - api

I gonna develop a form using slim framework. I know we can develop REST API's using SLIM. I need to know whether we can design forms and validate those.
Thanks in advance.

Slim doesn't give you these kind of utils. You could use external libraries to validate forms like Respect/Validation or you could use rapyd-framework (Notice that its development is now stopped),
a microframework built on top of Slim Framework, Twig, Symfony Forms,
Illuminate/Database, Twitter Bootstrap
that supports Symfony Forms.

Related

Boilerplate catalog skeleton

I have to make a simple catalog with products image upload with boilerplate.
Has anyone done something like this? Are there public examples of catalogs source code made with AspnetBoilerplate on the internet?
checkout the below websites.
https://www.nopcommerce.com/
https://www.wix.com/
But AspnetBoilerplate is a developer friendly framework and fully open to customizations. On the other hand, you need to write code and get your hands dirty with it. For the long-term benefits, I would go with AspnetBoilerplate.
Ready to use solution? Unlikely. AspnetBoilerPlate is for coders. So start coding. It should be fairly straightforward to hook up existing .NET Core e-commerce solution with AspNetBoilerplate features using starter template as a reference. Alternatively, you can start with AspNetBoilerplate starter template and add necessary e-commerce features like catalog listing using existing e-commerce source code as a reference.
SimplCommerce is a good simple ecommerce solution also built with .NET Core and EntityFrameworkCore.

how to convert yii 1 application to version 2

We have website which built in yii 1.1 version, now we would like to convert it to version 2. But we already have a lots of functionality and we do not have much time to do everything by scratch in yii 2. please do suggest.
I don't think there is a fast way of converting or migrating from Yii 1.1 to Yii2. They are similar in some ways but different enough.
I would recommend you first read most of The Definitive Guide to Yii 2.0, which includes Upgrading from Version 1.1.
In my opinion the best you can do is try to replicate the same modules and their functionality one at a time, trying to reuse as much code as you can from the 1.1 version. A few things that i think would be important are:
Create the new Yii2 models using Gii and adapt methods from your Yii 1.1 models. Edit and add validation rules as needed. There are many rules that might not have been available in Yii 1.1, however it can also be true the other way around.
Generate Yii2 modules with Gii. Just need these to create a better project structure. If you didn't use modules on Yii 1.1 i would recommend doing so for Yii2.
Generate Yii2 CRUDs with Gii inside the corresponding modules. This will help generate the controller, actions, views and search model needed for basic CRUD functionality. After that, you will need to edit the views and controller to fit your needs, which you can use your 1.1 code for reference.
Install needed extensions and widgets using composer. Many extensions from Yii 1.1 have updated versions for Yii2, but for those that do not you will have to find substitutes, which shouldn't be too difficult, although you will most likely have to read the documentation for both familiar and new extensions.
In the end you will need to spend time to have a Yii2 version of your website, there is no easy and fast way to jump
You don't need to convert your application completely you can use both at same time please have a look to
http://www.yiiframework.com/doc-2.0/guide-tutorial-yii-integration.html

ASP.NET MVC toolkit

I am coming from desktop dev background, wpf/SLight, and looking at switching to MVC application. Given I am absolutely rubbish at making stuff "pretty" what would be the best toolkit/widgets to invest in to help me on my way?
Looking for ease of use; UI look and feel; price?
I have experience with following control toolkit.
JQuery with JQuery UI : http://jqueryui.com/ Free and open source. Lot of community support, Lot of plugin to extend. you have more control over plugins and code. Very light. I have extensively use several mvic projects and I do recommend.
MVC controls toolkit. : http://mvccontrolstoolkit.codeplex.com/ - Free and open source code plex projects that you can use your mvc application.
DEvexprss mvc extension. http://mvc.devexpress.com/ : Commercial product with all necessary control for mvc application. Learning curve is bit high. But you can get very nice look for your application easily. Customization is difficult. They have good support from you technical issues. I have use for projects.
Kendo UI : http://www.kendoui.com/ commercial product from Telerik. I haven’t use in commrical project this but seems good.
One of the most popular UI frameworks is Twitter Bootstrap (FREE). It is built on top of jQuery and has lots of pretty widgets that are easy to use.
Another framework I like to use is KendoUI from Telerik (Price depends on what you need). It is very declarative so you simply need to add attributes to your html elements and it will take care of styling for you.

Writting My lightweight MVC framework

I have planned to write my own light weight MVC for PHP, that will be used as base for my sites I develop. I have no problem with PHP, OOP, et al. I have trouble on how to actually load Models In controllers and use them amd loading Controller values into Views. In short, I don't know how M-V-C interact behind the scenes.
Any tutorial (concentrating on that) or any contribution is welcomed!
Thanks!
ASP.NET MVC is open source: http://aspnet.codeplex.com/releases/view/58781
Edit: consider this: I believe you are trying to reinvent the wheel, thinking that those MVC framework out there are heavy and packed with uncessary features (acording to your double use of the word lightweigth). In my experience, I always ended up coding those extra "features" because a framework is required to evolve. Loading models In controllers, using them and loading controller values into views is just the begining. If you want to get started eventually, it would be a better investment to write some helper classes and methods: a popular pattern in the MVC world. Unless you are writing a MVC framework from scratch for fun and I am totally wrong (you said you needed a base to use for your sites ).
Best of luck!
Codeigniter is an open source MVC framework of php.
http://codeigniter.com/user_guide/overview/appflow.html
The major in MVC is first of all your controller class initiated and then calls view.
After google and check how other MVC works I decided to take this route. I redirect all my requests with .htaccess to index.php. Then there I define base paths. After all the definitions I include the core.php which in turn includes all core files to my mvc framework. Then in the same file I create Instances of Registry and router and the game starts from here!
Internals are a bit complex now but that is what I ended with!

Can we make use of the Sharp Architecture in a web application, without MVC?

I am a newbie to NHibernate. Just was thinking whether we can make use of the Sharp Architecture in a web application, without MVC?
Thanks.
Yes - you can use the repository/entity pattern without MVC. We use Sharp in an MVC application as well as a counter part desktop application.
Just reference Sharp.Core and Sharp.Data.