Showing posts with label what. Show all posts
Showing posts with label what. Show all posts

Sunday, January 22, 2017

What is Scaffolding

What is Scaffolding



in the previous tutorial Creating To Do list Application in CakePhP we have used a variable var $scaffold well almost everyone of you would be wondering what was that and why did we used it well answer is very simple. For CRUD (Create, Replace, Update, Delete) operations we used this variable. Once we inserted this variable in our controller we got the full fledge functionality of having the CRUD functionality in our Application. 

Cakephp scaffolding is very cool and it gives you the crud availability in minutes so you dont have to write really large code for everything.

To add the scaffold to your application you just have to paste this code in your controller section as shown below
 <?php 
class CategoriesController extends AppController {
var $scaffold;
}
?>


Go to link Download

Read more »

What is the difference between OSPF E2 Routes and E1 Routes

What is the difference between OSPF E2 Routes and E1 Routes


Look at the figure above, when using OSPF dynamic routing, all routers exchange Link-State Packets between each Router. Router A is Autonomous System Border Router (ASBR) because it advertises external link to internal Routers. With RIP, IGRP, EIGRP the external network is in one type, but with OSPF the external network is redistributed by 2 types: E1 and E2

R1#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

E2 is the default routes type for routes learned via redistribution. For example, Router C and other routers in the routing domain will learn external networks that Router A redistribute with cost from Router A to external network.

If Router A is configurable with E1. At this time, Router C in the routing domain will learn external networks via Router A with cost is cost of Router C to Router A and Router A to destination network
RA#conf t
Enter configuration commands, one per line. End with CNTL/Z.
RA(config)#router ospf 1
RA(config-router)#redistribute rip subnets metric-type 1
After configure external type 1, the cost from RouterC to External network is larger the cost from RouterC to external network with E2 configuration.

Go to link Download

Read more »

Monday, January 16, 2017

What is jusched exe Virus or Error Remove it from Windows 7

What is jusched exe Virus or Error Remove it from Windows 7


Hello friends, JAVA is an important programming language and its software (Run Time Environment) must be installed on your computer in order to run other software and website well. But due to JAVA jusched.exe error is occurred. I’m here with guide on what is jusched.exe? Virus or Error? How to remove it from Windows 7.

I’m going to first tell you that what is this program and then I’ll clear the confusion in your mind whether it’s a virus or malware and then I’ll provide you the guide for removing it from Windows 7. So come with me,

What is jusched.exe error or process
Read more »

Go to link Download

Read more »

Monday, January 2, 2017

What Is Google Now and How Do I Use It

What Is Google Now and How Do I Use It


What Is Google Now and How Do I Use It?

When Jelly Bean was officially announced, Android users had a lot to be excited about. The latest version of the OS is super-smooth (like Butter!), there are expandable notifications that actually include functionality, there is a better keyboard, better widgets, and a better camera/gallery.
The biggest announcements, of course, were the addition of a better voice search, and with it, Google Now. So what is Google Now? Let’s find out!
Google Now is still very much in beta, so I will keep that in mind as a talk about it.
Google Now, as Google puts it, “brings you just the right information at just the right time”. The idea is that Google Now will use everything it ‘knows’ about you to deliver timely information based on your schedule, location, hobbies, time of day, and more.

Cards

Google Now presents you with this information using what they call Cards, and Android will notify you when a new Card pops up (based on your settings). For example, Google Now hit me with this card during the Yankees/Red Sox game because it knows the Yankees are my favorite baseball team:
Low blow, Google. Low blow.
I’ve organized the information Google Now presents you into two categories: Day-to-Day and Travel. Let’s look at Day-to-Day first.
To access Google Now, you just need to press ‘Google’ in the search bar that appears at the top of each screen, or swipe up from the Home button.

Day-to-Day Information

Part of what Google Now presents to you is information that will help get you through the day. This includes:
  • Weather
  • Traffic
  • Appointments
  • Public Transit
  • Sports
  • Places Nearby (which can be in both categories)
I’ve already shown you Sports. Google Now will use you previous searches to determine which teams you’re interested in and present you real time scores of those games. You can easily manage teams in the Settings, in case Google picks up a team you don’t really care for.
Weather is probably pretty self-explanatory; it will get your location and give you the current conditions as well as the five-day forecast. There is an option to always display this card or only display it in the morning or in the evening (for the next day’s forecast).
Local Weather

Public Transportation and Places Nearby

Both Public Transportation and Places Nearby are based on the location reading from your device’s GPS. Public Transportation will give you schedules when you’re near a Bus or Train station, as well as ‘when traveling.’
Places Nearby will show you exactly that: notable places in the area. This one is a bit interesting. I’ve been using Jelly Bean for a couple of weeks now but I can’t tell how Google Now discerns what is notable to show you. I did notice that some time after I Googled ‘Chic Fil-A’ to read up on all the recent hubbub surrounding the company, Google Now told me when I was near an establishment, but I believe there is more to it than just Google searches.
Public Transportation and Nearby Places

Appointments and Traffic

Appointments and Traffic could very well be the most useful as far as day-to-day stuff goes. With Appointments, Google Now will grab your next appointment from your calendar and display it as a card as the appointment approaches. If travel is required, it will notify you the day of, and bring up a Traffic card that gives you a traffic report and a link to directions, which is really cool!
Speaking of the traffic card, here is the description according to Google:
Get traffic conditions and alternate routes before you leave for work. Google Now also puts traffic to your next likely destination at your fingertips.
While I have experienced the latter, my commute has actually been somewhat erratic over the last couple of weeks as I’ve been running errands or making stops along the way, so my phone hasn’t been able to get a good idea of my commute. However, it has noticed I’ve been stopping at the Starbucks on campus and tells me about ones nearby when I leave work. I think as this service learns, it will get considerably better. I’ll be very interested to see how it does in a couple of months time.
Traffic based on recent search.

Travel Information

There are some services I didn’t mention above that I think better fit into the category of Travel Information. They are:
  • Flights
  • Translation
  • Currency
  • Time Back Home
Places Nearby would also qualify for this section, as I’d imagine you could probably rely on it a bit in an area you’re unfamiliar with.
Flights will grab information on flights you’ve searched for with Google and give you updates on status and traffic to the airport. This is a pretty interesting one because (since I haven’t flown since getting Jelly Bean) I’m not exactly sure how it works. My inclination would be that it could grab the flight info from your calendar, but that doesn’t seem to be the case. The card looks very cool and the idea is great, but the jury is still out on how well it works for me.
Upcoming Flight Info
Translation, Currency, and Time Back Home are much more intuitive as far as functionality and usage go. Google will grab your location and show each of the three based on the following (respective) criteria: you visit a place with a different language, you visit a place with a different currency, or you’re in a different time zone from the one you’re normally in. It would seem that with the former two, Google takes its best guess at which language and currency is being used.
Travel cards (images from Google Now’s official site)

Thoughts

The idea behind Google Now is a great one — it’s a personal assistant that doesn’t need to be engaged by the user. Theoretically, it should just work. It will also learn based on your habits and search history, which is a fascinating concept. Of course, you can be as open with it or as private as you’d like; if location and web history aren’t turned on, Google Now won’t give you too much information as it’s not getting much from you.
I’m not going to rate it because I don’t think it really fair. I haven’t travelled outside of where I live while using it and for some functionality, I haven’t given good enough patterns for it to work to it’s full potential. It’s also still in beta. I will say that from what I’ve seen, it is very cool and incredibly helpful at times. It has some very serious potential, as well as implications for the future of mobile devices.

Go to link Download

Read more »

Friday, December 30, 2016

What is Query MS ACCESS

What is Query MS ACCESS


All of the queries that you have created to this point have been variations of “select” queries. Select que-ries are used to display data but do not actually change the data in any way.


Queries, in contrast, are used to change the data in existing tables or make new tables based on the querys results set. The primary advantage of action queries is that they allow you to modify a large number of records without having to write Visual Basic programs. Access provides four different types of action que-ries:

1. Make table— creates a new table based on the results set of the query;
2. Append— similar to a make-table query, except that the results set of the query is appended to an existing table;
3. Update— allows the values of one or more fields in the result set to be modified; and,
4. Delete— deletes all the records in the results set from the underlying table.

Go to link Download

Read more »

Sunday, November 27, 2016

What is the Spyware

What is the Spyware



What is the Spyware?




How to Remove Spyware?

How do I get divest of Spyware Spyware is placed on your computer without your knowledge. It ‘something used to spy on you and your activities on your computer. Spyware is placed on your computer without your knowledge, and a lot of time people do not even realize that they were infected. You can also take over the computer and perform the tasks you want to do it.

It can be used to record keystrokes, screen info, email logs, chat, your Internet activity and information from the hard drive. If you have spyware on your computer, you must get rid of spyware fast. Spyware can make changes to the settings of your computer, and these changes may be difficult to reverse. It may make changes to your site files on your hard drive, and also steal valuable information from you. How to get rid of spyware?

First, you scan your computer with a particular type of software that will scan and remove spyware. You can search forever online for spyware programs, and there are quite a few there. Some of them work, some do not. There are many programs out there, but I did find some that really work. There are links at the bottom of this page for the software. Some of them even allow you to scan your computer first before buying.

I would recommend considering buying this software, even as they provide only a free scan to scan and delete as suggested. Let me tell you that if you have spyware on your computer to remove spyware as soon as possible. I think you should also scan your computer for spyware at least once a month, maybe twice a month, if you will not notice that your computer is infected with spyware.

How to Remove Spyware:

There is lots of free Anti-spyware software available on web. You can download any of them and install it in your computer. After finishing installation process, just disconnect computer from internet or any kind of local network. Restart the computer once. After restarting computer, start installed anti-spyware for full computer scanning. It would be scanning whole computer and find out infected files. Remove those files and restart again your computer and add internet or network cable. If you perform this scanning activity 2-3 times at first time then make sure that internet and network cable must be un-plugged before activity.





Go to link Download

Read more »

Thursday, November 24, 2016

What is IBPS and its role in banking selection

What is IBPS and its role in banking selection



What is IBPS and its role in banking selection



he origin of banking sector in India could be traced back to 18century with the advent of British in India. The private banks although gave very prompt services to the customers, but failed to win the confidence of their customers, in their capability to provide security to their money. The customers could not bestow their full faith in the private banks. The trust of the customer is the prime factor in banking sector and the same was missing .Thus the private banks could survive but were unable to flourish in spite of their all out efforts.

The nationalization of private banks in India was the turning point in the banking history, as it gave the whole hearted support and trust of the people in the banks as they knew that if the banks failed to pay their money then the Government will pay the money. Hence the banks started enjoying the whole hearted confidence and trust of the people. Thus the banking in India started growing with leaps and bounds. The growth brought with it good profits for banks ,and they started looking towards attracting better talent towards the banking sector .Hence need for a organization was felt, which could solely undertake the responsibility of conducting exams, selecting right  personnel for the banking sector and to formulate such a pattern of exams so that only right candidate is selected. Thus originated the institution of banking personnel selection or IBPS.

What is IBPS ?

Institution of Banking Personnel Selection was established in the year 1975 with the sole objective of selecting the right candidates for the banking sector. The candidates, who have natural flair for the banking sector, and who could face the challenges of the near future, and can take the banking sector to new heights of success and growth. The success of the institution can be attributed to the growth of banking sector since 1975.

Multidimensional Role of IBPS in banking sector of India.

The IBPS designs the pattern of exams, conducts the exam and finally selects the right candidates through interviews. The introduction of latest pattern of examination shows the vigilant attitude of the institution. Test of reasoning, logical thinking and various exams to test the ability of the candidate in conducting the normal working of the bank with the fastest possible way without committing mistake ,gave fillip to banking in India. In fact the IBPS played a pivtol role in the growth of banking sector in India. Read latest IBPS Exam.

IBPS as co-coordinator between banks

IBPS made the selection process for banks very easy it conducted the exams on a very scientific pattern and gave the banks list of success full candidates to call for interviews. As the time progressed it developed the pattern of common entrance examination pattern for various banks. The candidates are provided with score card, and the marks scored by the candidate respectively. This score card and the marks is to be mentioned, while applying in the various banks for the post, for which the candidate has given the common entrance exams .Thus banks are left with the task of conducting interviews and selecting the candidate.

IBPS as Trouble shooter

IBPS worked  as trouble shooter for the banks .As it saved the banks from the trouble of selecting the right candidates without being indulged in the bad practices of regionalism, nuptials and above of all the examination was not confined to the local level .Hence inviting the talents from all over the India. Thus every bank was enriched with the best talent available in India.

Hence one cannot deny the role played by IBPS in the growth of banking sector in India. In fact the banks in India can be proud of the fact that they are key role players in the most stable and growing economy of the world.




Go to link Download

Read more »

Tuesday, November 22, 2016

What are you going to get from Apple this year Apples Latest Updates by rafomac

What are you going to get from Apple this year Apples Latest Updates by rafomac


Apple made some huge announcements today. The first of this kind after the keynote legend , Steve Jobs , passed away. Today’s keynote presentations were pretty big for Tim Cook and team at Apple. It signified a major product series launch. It defines the future of Apple in a way. Though I missed the charisma Steve had  when he delivered keynotes for the core products, If he was alive, he would’ve proudly told us how he was able to leverage the crucial cash balance to outbalance the most important application in  iPhones and iPads, the Maps.





display
Apple has introduced a series of new products at the WWDC’12 keynote series , starting off a week of developer presentations and tutorials and so on. Though it was very much costlier than the earlier WWDC’s , the attendance was full .The tickets to WWDC was sold out in hours. This is remarkable considering that the key person who was the reason for seats to get filled is no more in this world. But people certainly believe that Apple is in good hands. And it did pay off, at least this year it did.
So , I will round-up the major announcements made up at the WWDC ,

iOS 6

iOS 6 was almost certainly expected out of this year’s WWDC as it has become a tradition , as Scott Forstall rightly pointed out during his keynote  of iOS6,  for Apple to release a new version of the OS at WWDC . iOS6 has vastly improved , both feature-wise and usability wise.
Key features noted are :


  • A more advanced Siri , who can respond to personalized queries about sports , actresses and literally everything under the sun now.  Tight integration with feed providers like Rotten Tomatoes for Movies , Yelp for Restaurant ratings and other content providers have enabled this rich functionality addition to Siri.siri_gallery_restaurants
  • Chinese support . To write , to read and to socialize. iOS6 has features for interaction in Mandarin  through Haiku , Baidu and other popular Chinese websites.more_china

  • Facebook integration  . A single sign on  ( just like Twitter integration in iOS5 ) , will enable you to update and post from almost all the apps with unlimited combinations to your friends.facebook_gallery_contacts
  • Lost & Found feature lets you display your backup phone number on the lock screen by triggering it through your Mac or another phone number  when you lose your phone. The finder can just click on it and call you right away.more_fmip
  • Improved Safari – with native support to Chinese , Unified search bar ( Much like Omnibox
  • in Google Chrome ).
  • Voice mail shortcuts on the Phone screen – A feature slightly ripped off from Android , I must say. But they have improved on it . As usual !.   It now features a temporary whitelisting when a caller calls you ( or nags you ) multiple times, odds are that it will be important.
  • phone_gallery_reply_1phone_gallery_reply_2phone_gallery_disturb_2

 

 

 

 

 



Maps

This was the most anticipated feature of all. Maybe even more than the iOS6 as a whole. This position taken by Apple seriously threatens the revenue generation of Google and their data collection as well. Apple has decided to part their ways with Google on the Maps , mainly owing to the fact that they didn’t like Google collecting location details of all Apple devices  when they themselves had huge amount of applications of it.
Rightly so , Apple has implemented a lot of cool and useful features into their own version of Maps.
  • Turn by Turn Navigation  on most cities. Ofcourse , Siri will be guiding you. Who else do you expect to guide you properly.  maps_gallery_turnbyturn_2
  • FlyOver – Coolest feature you would ever want in a Maps application, But Google has already managed to do a similar data usage on their new version of Maps last week itself. Flyover takes you through a 3D flyover over select cities , by utilizing the vector models of the cities collected by Apple.maps_gallery_flyover

 

MacBook Pro

While they mostly updated the technical specs alone on their MacBook Air line up, Apple has whipped up a useful and flashy move on the MacBook Pro lineup. For starters , they killed off the 13” and 17” Macbook Pro’s . Then they decided to remodel the entire philosophy behind MacBook, not just the physical form.
As a result, We got this :gallery4_2256
It’s certainly thinner , sleek and elegantly beautiful. More than the MacBook Air  in a certain way. Tightly packed aluminium body with the display crafted into the unibody structure . Only Apple can make a win-win with this kind of innovation.
They have added some extras onto this :
  • USB 3.0
  • Bluetooth 4.0
  • Thunderbolt ports
  • HDMI
  • Nvidia GT 650 M – a welcome addition to the Mac Line-up.
  • 8 GB of 1600 MHz DDR3L RAM
They have removed certain features as well :
  • Optical Drive
  • Magnetic Hard Disk
  • Boring Old Display
  • Noisy Fan
The key feature of the new MacBook Pro line up is it’s elegant display. Crafted into the aluminum and insanely thin. But with a whopping resolution of 2880×1800 pixels. Oh yeah, that’s a huge amount of pixels to be on a 15.4” screen. And Apple is calling it , the Retina Display . Yes, MacBook is getting it finally!.
Also , it has a 256 GB / 512 GB Flash storage. Apple decided to finally respond to a decade old problem of slow I/O devices. They chucked the magnetic hard drives. And they decided to top it off by removing the optical drive as well. Remember , Apple removed FDD’s from the iMacs , causing it to become obsolete . This will repeat again , I’m sure of that.gallery3_2256 





Go to link Download

Read more »

What is System Restore How to Create a System Restore Point in Windows 7 8 XP Vista

What is System Restore How to Create a System Restore Point in Windows 7 8 XP Vista


System Restore helps you restore your computer's system files to an earlier point in time. It's a way to undo system changes to your computer without affecting your personal files, such as e?mail, documents, or photos.

Sometimes, the installation of a program or a driver can cause an unexpected change to your computer or cause Windows to behave unpredictably. Usually, uninstalling the program or driver corrects the problem. If uninstalling doesn't fix the problem, you can try restoring your computer's system to an earlier date when everything worked correctly.

Read more »

Go to link Download

Read more »

Friday, November 18, 2016

What Is The Difference Between 32 bit 64 bit Windows

What Is The Difference Between 32 bit 64 bit Windows


“What is the difference between a 32-bit and 64-bit Windows operating system?” Most of you are running Windows XP or Vista in its 32-bit iteration. But as hardware gets cheaper, people are curious as to what the 64-bit operating system has to offer. First let’s see if we can grasp the difference between 32- and 64-bit.

Think of your computer as a series of tubes that can either be 32 or 64 bits wide. When you have the smaller 32-bit size, there is more potential for bottlenecks to occur. Bottlenecks slow down your system because one process has to wait for another to finish before it can begin. But if you want to have 64-bit wide tubes, your computer needs to be thinking in 64-bit so your software and hardware all need to support 64-bit.

If you do not know the difference between 32-bit and 64-bit, I would have told you in the past that you are running a 32-bit version of Windows. But now with Windows 7 I am seeing more and more 64-bit operating systems shipped by default without the end users knowledge. Don’t get me wrong, a 64-bit system is better but you also need to be running 64-bit programs and have a 64-bit processor or else all the trouble of setting up the 64-bit operating system would be worthless.

On a 32-bit operating system, you are restricted to a maximum of 3 gigabytes of RAM. On a 64-bit operating system, you really do not have a limit. Let’s look at Wikipedia and find out the maximum amount of RAM for a 64-bit operating system:

264 addresses, equivalent to approximately 17.2 billion gigabytes, 16.3 million terabytes, or 16 exabytes of RAM.
That is a huge amount of RAM! Normally when you exhaust your physical RAM on a 32-bit system, it has to use virtual memory or hard disk space to pick up the slack. On a 64-bit system, you can install as much RAM as you can to cover your overhead. From here on, 32-bit operating systems will be referred to as x86 and 64 bit operating systems as x64. You can tell what you are running by right clicking on My Computer and choosing Properties.  Below is a shot of a 64-bit machine using 12GB of memory.

 
And in this shot, we see a 32-bit machine trying to use 7GB of RAM.. Not going to happen!
 

If you are running 3D modeling systems or AutoCAD systems, you can benefit from a x64 bit architecture but remember, you need to be running ALL x64 applications, print drivers and anything else you are setting up on your system to realize its full potential. Not all programs have been created for x64 yet and you will find yourself installing applications to your Program Files x86 directory. On a x64 machine, you will have two Program File directories — one for 32-bit and one for 64-bit applications.
So after reading through that and you still want to run a x64 operating system, you will need to make sure your processor supports x64. Most new servers and new computers bought this year or beyond will support x64 but you will still need to check. Here are some facts you should know:
  • Almost all new servers sold within the last two years from AMD or Intel will have x64 capability.
  • Most mid- to high-end desktop processors from AMD or Intel within the last year have x64 capability.
  • Some higher-end Semprons have x64; lower-end Semprons do not.
  • No AMD Durons have x64.
  • All AMD Opteron processors have x64.
  • All AMD X2, FX, and Athlon64 chips have x64.
  • All Intel Pentium D and Celeron D chips have x64.
  • All AMD Turion notebook processors have x64.
  • All Intel Core 2 processors (mobile, desktop, and server) have x64.
  • No Intel Core Duo notebook processors have x64
  • No Intel Pentium M notebook processors have x64.
If you are still not sure if your processor can support x64 check out GRC’s SecurAble and let them help you figure it out! You might also want to check out Mahendra’s post How To Choose Between 32-bit & 64-bit Windows 7 Operating Systems.

If you are running a server that has all its hardware and software certified for x64, then you should install the 64-bit version but beware of device drivers and any 32-bit environments because if I used the word difficult, it would be an understatement!



Go to link Download

Read more »

Saturday, November 12, 2016

What is MVC

What is MVC


ASP.NET MVC
Visual Studio

The MVC Programming Model

MVC is one of three ASP.NET programming models.
MVC is a framework for building web applications using a MVC (Model View Controller) design:
  • The Model represents the application core (for instance a list of database records).
  • The View displays the data (the database records).
  • The Controller handles the input (to the database records).


The MVC model also provides full control over HTML, CSS, and JavaScript.

The MVC model defines web applications with 3 logic layers: 

The business layer (Model logic)

The display layer (View logic)

The input control (Controller logic)

The Model is the part of the application that handles the logic for the application data.
Often model objects retrieve data (and store data) from a database.
The View is the parts of the application that handles the display of the data.
Most often the views are created from the model data.
The Controller is the part of the application that handles user interaction.
Typically controllers read data from a view, control user input, and send input data to the model.
The MVC separation helps you manage complex applications, because you can focus on one aspect a time. For example, you can focus on the view without depending on the business logic. It also makes it easier to test an application.
The MVC separation also simplifies group development. Different developers can work on the view, the controller logic, and the business logic in parallel.


MVC Folders :

A typical ASP.NET MVC web application has the following folder content:
Application information
Properties
References
Application folders
App_Data Folder
Content Folder
Controllers Folder
Models Folder
Scripts Folder
Views Folder
Configuration files
Global.asax
packages.config
Web.config








The folder names are equal in all MVC applications. The MVC framework is based on default naming. Controllers are in the Controllers folder, Views are in the Views folder, and Models are in the Models folder. You dont have to use the folder names in your application code.
Standard naming reduces the amount of code, and makes it easier for developers to understand MVC projects.
Below is a brief summary of the content of each folder:



The App_Data Folder

The App_Data folder is for storing application data.
We will add an SQL database to the App_Data folder,



The Content Folder


The Content folder is used for static files like style sheets (css files), icons and images.

Visual Web Developer automatically adds a themes folder to the Content folder. The themes folder is filled with jQuery styles and pictures. In this project you can delete the themes folder.

Visual Web Developer also adds a standard style sheet file to the project: the file Site.css in the content folder. The style sheet file is the file to edit when you want to change the style of the application.
We will edit the style sheet file (Site.css) file in the next chapter of this tutorial.





The Controllers Folder


The Controllers folder contains the controller classes responsible for handling user input and responses.

MVC requires the name of all controller files to end with "Controller".
Visual Web Developer has created a Home controller (for the Home and the About page) and an Account controller (for Login pages):
We will create more controllers later in this tutorial.










The Models Folder

The Models folder contains the classes that represent the application models. Models hold and manipulate application data.
We will create models (classes) in a later chapter of this tutorial.



The Views Folder


The Views folder stores the HTML files related to the display of the application (the user interfaces).
The Views folder contains one folder for each controller. 
Visual Web Developer has created an Account folder, a Home folder, and a Shared folder (inside the Views folder).
The Account folder contains pages for registering and logging in to user accounts.
The Home folder is used for storing application pages like the home page and the about page.
The Shared folder is used to store views shared between controllers (master pages and layout pages).

We will edit the layout files in the next chapter of this tutorial.




The Scripts Folder


The Scripts folder stores the JavaScript files of the application.
By default Visual Web Developer fills this folder with standard MVC, Ajax, and jQuery files:






Go to link Download

Read more »

Friday, November 11, 2016

What is Query String and How to use it

What is Query String and How to use it


What does Query String mean?

A query string is the portion of a URL where data is passed to a Web application and/or back-end database. The reason we need query strings is that the HTTP protocol is stateless by design. For a website to be anything more than a brochure, you need to maintain state (store data). There are a number of ways to do this:

  • On most Web servers, you can use something like session state server-side. 
  • On the client, you can store via cookies. 
  • Or in the URL, you can store data via a query string.

------------------------------

How to use Query String in Visual Studio ASP.NET MVC 


We can use Query String using three Ways
  1. By URL
  2. By Hyper link
  3. By form

  1. By URL :

Go to HomeController.cs and add string name as a parameter in “index” action method. (here we use “index” page to show data)

public ActionResult Index (string name)
{
      return view();
}



At this point, data reached to ActionMethod index of Home controller but we still dont send data from this action method to Index view
Now to send data from action method to view,there are two ways
  1. ViewBag
  2. ViewData
The difference between the syntax of these is as follows
ViewBag.f_name = waqas;
ViewData["f_name"] = waqas;

Now again go to HomeController.cs and add ViewBag line in the same Action Method

public ActionResult Index(string name)
{
      ViewBag.fName = name;
      return View();
}

Now we are sending data to index view ..Now well receave data at index view.
For this add following code in Index view 

<h1> You Enter @ViewBag.fname </h1> //we use @ while writing c# code. This is Razor Syntex

Now Run the project and Go to following URL

              localhost:2342/home/index? name=Irfan

Now “You Enter Irfan” is Showing on Webpage. This is the method how we use Query String using URL
---------------------

      2. By Hyper Link

after adding the code to "Index Action method" and "Index View". Add the following hyper link link to the "Index" view

<a href="/home/success?name=Irfan"> Click Here </a>

Now Run the project, after clicking on this Link,
"You Enter Irfan" will will be shown on the webpage.

This is how we use Query String using Hyper link

---------------------

      3. By Form


Now well see how to use Query String using From.
Add following form in this “Index” view.

<form action="/Home/Success" method="post">
      <input type="text" id="name" name="name" />
      <input type="password" id="pass" name="pass" />
      <input type="submit" value="sign up" />
</form>

Now well create another Action Method and a View where we want to display data that we enter using form.
Create a ActionMethod in HomeController and named it “Success” (you can use any name)

public ActionResult Success( )
{
      return View();
}

Add a View in Home folder and named it Success.cshtml. (use the same name as Action method)
Now add the following code to the “Success” Action Method


public ActionResult Success(string name,string pass)
{
      ViewBag.fName = name;
      ViewBag.password = pass;
      return View();
}

we add Parameters to get data to this action method. We use ViewBag to send data to Success.cshtml View.
Now to receive data in Success.cshtml, we again use @ViewBag in “Success” View

<h1@ViewBag.fName </h1>
<h1@ViewBag.password </h1>

Now run the project and visit Index page. Add data in text fields and click on Submit.
That data will be displayed on Webpage.






Go to link Download

Read more »