Go Back   Site Owners Forums - Webmaster Forums > Web Programming > Programming General > PHP / mySQL

Notices


Reply
 
Thread Tools Rate Thread Display Modes
Old 09-24-2017, 10:10 PM   #1
eventplanner779
Registered User
 
Join Date: Sep 2017
Location: Delhi
Posts: 42
what types of loops exist in php ?

what types of loops exist in php ?
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
eventplanner779 is offline   Reply With Quote

Old 09-26-2017, 05:22 AM   #2
travelowebseo
Registered User
 
Join Date: Sep 2017
Posts: 224
PHP supports following four loop types. for − loops through a block of code a specified number of times. while − loops through a block of code if and as long as a specified condition is true. do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
travelowebseo is offline   Reply With Quote
Old 11-03-2017, 12:14 AM   #3
thevyakar
Registered User
 
Join Date: Nov 2017
Location: USA
Posts: 75
for
while
do..while
foreach
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
thevyakar is offline   Reply With Quote
Old 11-09-2017, 12:18 AM   #4
Shalini001
Registered User
 
Join Date: Oct 2017
Posts: 27
PHP supports following four loop types. for − loops through a block of code a specified number of times. while − loops through a block of code if and as long as a specified condition is true. do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.
Shalini001 is offline   Reply With Quote
Old 11-23-2017, 07:37 AM   #5
Lebar.123
Registered User
 
Join Date: Nov 2017
Posts: 463
All that exist in all other languages:

For While Do While ForEach.
__________________
Get your email validated by our
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
@ ZeroBounce
Lebar.123 is offline   Reply With Quote
Old 11-23-2017, 09:47 PM   #6
seven miles
Registered User
 
Join Date: Nov 2017
Posts: 91
PHP supports following four loop types.

for − loops through a block of code a specified number of times.

while − loops through a block of code if and as long as a specified condition is true.

do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.

for each − loops through a block of code for each element in an array
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
seven miles is offline   Reply With Quote
Old 12-22-2017, 04:28 AM   #7
BryceBrady
Registered User
 
Join Date: Oct 2016
Posts: 580
PHP supports following four loop types.
for − loops through a block of code a specified number of times.
while − loops through a block of code if and as long as a specified condition is true.
do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
BryceBrady is offline   Reply With Quote
Old 12-26-2017, 03:57 PM   #8
nele
Registered User
 
Join Date: Aug 2013
Posts: 79
Loops in PHP are used to execute the same block of code a specified number of times. PHP supports following four loop types.

for − loops through a block of code a specified number of times.

while − loops through a block of code if and as long as a specified condition is true.

do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.

foreach − loops through a block of code for each element in an array.
__________________
"Powerfull state of the art DELL servers!"

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
- Ultimate Windows VPS hosting | Dedicated hardware MS Hyper-V technology Premium bandwidth providers

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
- Chat support Full 24/7 help desk support Email support
nele is offline   Reply With Quote
Old 12-28-2017, 04:12 AM   #9
yuvashri
Registered User
 
Join Date: Jun 2017
Posts: 335
PHP supports following four loop types. for − loops through a block of code a specified number of times. while − loops through a block of code if and as long as a specified condition is true. do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
yuvashri is offline   Reply With Quote
Old 01-05-2018, 03:04 AM   #10
aesthetiqclinic
Registered User
 
Join Date: Jan 2018
Posts: 230
php support four type of loops
1. for loop: mostly used to repeat a code for specified number of times.
2. while loop: use to repeat a code until the test condition remains true.
3. do-while loop: at least one time execution of code. after that code execution depends upon condition.
4: foreach: execute a block of code for each element of array
aesthetiqclinic is offline   Reply With Quote
Old 01-18-2018, 03:44 AM   #11
exproacademy
Registered User
 
Join Date: Oct 2017
Posts: 11
Types of loops in PHP

1. for
2. while
3. do...while
4. foreach
exproacademy is offline   Reply With Quote
Old 01-18-2018, 04:24 AM   #12
marvinsam
Registered User
 
Join Date: Apr 2016
Posts: 542
There are 3 types of loops are there in php.

1. For
2. While
3. Do while
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
marvinsam is offline   Reply With Quote
Old 02-18-2018, 09:42 PM   #13
aesthetiqclinic
Registered User
 
Join Date: Jan 2018
Posts: 230
There are 4 types of loops in PHP and that are For Loop, While Loop, Do While Loop and foreach Loop. they are used to loop all the data or any record to do different tasks.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
aesthetiqclinic is offline   Reply With Quote
Old 02-25-2018, 02:21 AM   #14
smmexpertss
Registered User
 
Join Date: Sep 2015
Location: UK
Posts: 447
oops in PHP are used to execute the same block of code a specified number of times. PHP supports following four loop types.

for − loops through a block of code a specified number of times.

while − loops through a block of code if and as long as a specified condition is true.

do...while − loops through a block of code once, and then repeats the loop as long as a special condition is true.

foreach − loops through a block of code for each element in an array.
smmexpertss is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Importance of Php Development for Web Development tech.biztech Programming General 35 11-22-2019 12:37 AM
How many types of joining in php mark1 PHP / mySQL 9 02-17-2017 07:00 AM
What are Loops in Java? What are three types of loops? Shivangi Panwar Java 6 06-20-2016 04:02 AM
Explain the different types of errors in PHP. Broach India Programming General 6 03-13-2015 10:23 PM
PHP project training in ahmedabad, live project training in php ahmedabad anantitsolution Post your ad here 1 07-16-2013 07:42 PM


All times are GMT -7. The time now is 07:20 PM.


Powered by vBulletin Copyright © 2020 vBulletin Solutions, Inc.