Ad block is installed and active. Please support us by disabling it.
HomeSunday, November 19, 2017, 13:54:24
1

MySQL – Select from two tables

Monday, February 9, 15, 01:14:59, 3 Yaers Ago Via wain, Hits: 3200
Select data from two tables, PHP MySQL
Code:
<?php
$result = mysql_query("SELECT id, text FROM base_one")
or die(mysql_error());
while($row=mysql_fetch_array($result)){
$resultb = mysql_query("SELECT id, text FROM base_two
WHERE id=".$row['id']." ORDER by text ASC")
or die(mysql_error());
while($link=mysql_fetch_array($resultb)){
echo $link[text];
echo "<br />";
}
}
?>

Sign In

Sponsor

Related

Random MySQL Query

Random MySQL query, requirement(s): PHP Server, MySQL

Preg_Match - PHP Email Validation

Validate email with preg_match in php

FeedBack Form with Captcha

It allows your visitors to send you an email directly from your website.

Email to Friend - PHP Script

This form allows your visitors to suggest your site to a friend. It features an HTML email format and an admin notification email.

Contact Us Form With Captcha

A contact us form with email and form field validation. It allows your visitors to send you an email directly from your website. Features: Captcha Image, HTML output.

PHP Form Validation

PHP form validation :: PHP tutorial, requirement(s): PHP Server

Upload and Resize an Image with PHP

Tutorial - How to upload and resize image with PHP

PHP/MySQL Bookmarklet - PHP Tutorial

PHP/MySQL bookmarklet, bookmark current page, PHP/MySQL tutorial.

php Array

These functions allow you to interact with and manipulate arrays in various ways. Arrays are essential for storing, managing, and operating on sets of variables.

MySQL Tutorials

MySQL tutorials, MySQL training, learn MySQL, MySQL Tutorial with practical examples.
About Author

wain

Date Registered: Sun, Feb 8, 15
Last Time Online: Thu, Jun 15, 17
So far has created 115 entries.
wain
This author has not yet filled in any details.