Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?
- class Query
- {
- function get_city_love($country_id)
- {
- $query = "
- SELECT
- *
- FROM
- `сity_love`
- WHERE
- `сity_love`.`id` = '$country_id';";
- $query_result = mysql_query($query) or die("Query failed : " . mysql_error());
- $country = $query_result['city_id'];
- $this->Country = $country;
- }
- function country_finish($country_id)
- {
- $query = "
- UPDATE
- `city_love`
- SET
- `city_love`.`is_finish` = 'finish'
- WHERE
- `city_love`.`id` = '$country_id';";
- mysql_query($query) or die("Query failed : " . mysql_error());
- }
- function love_set_position($male, $male_meet, $to, $country_id, $i)
- {
- echo 'position'.$male.','.$male_meet.','.$to.','.$country_id.','.$i;
- $query = "
- UPDATE
- `love_position`
- SET
- `love_position`.`male` = '$male',
- `love_position`.`male_meet` = '$male_meet',
- `love_position`.`to` = '$to',
- `love_position`.`country_id` = '$country_id',
- `love_position`.`i` = '$i'
- WHERE
- `love_position`.`id` = '1';";
- mysql_query($query) or die("Query failed : " . mysql_error());
- }
- function love_get_position()
- {
- $query = "
- SELECT
- *
- FROM
- `love_position`
- WHERE
- `love_position`.`id` = '1';";
- $position = mysql_query($query) or die("Query failed : " . mysql_error());
- $this->Position = $position;
- }
- function insert_values_mamba_main($account,$user_name,$city,$age,$about,$user_info,$i_meet,$zodiak)
- {
- $account = mysql_real_escape_string($account);
- $user_name = mysql_real_escape_string($user_name);
- $city = mysql_real_escape_string($city);
- $age = mysql_real_escape_string($age);
- $about = mysql_real_escape_string($about);
- $user_info = mysql_real_escape_string($user_info);
- $i_meet = mysql_real_escape_string($i_meet);
- $zodiak = mysql_real_escape_string($zodiak);
- $query = "
- INSERT
- INTO
- `mamba_main`
- VALUES
- (default,
- '$account',
- '$user_name',
- '$city',
- '$age',
- '$about',
- '$user_info',
- '$i_meet',
- '$zodiak');";
- mysql_query($query) or die("Query failed : " . mysql_error());
- }
- function insert_values_main_loveplanet($link,$about,$name,$user_info,$zodiak)
- {
- $link = mysql_real_escape_string($link);
- $about = iconv("UTF-8", "UTF-8", $about);
- $about = mysql_real_escape_string($about);
- $name = mysql_real_escape_string($name);
- $user_info = mysql_real_escape_string($user_info);
- $zodiak = mysql_real_escape_string($zodiak);
- $query = "
- INSERT
- INTO
- `loveplanet_main`
- VALUES
- (default,
- '$link',
- '$name',
- '$user_info',
- '$about',
- '$zodiak');";
- mysql_query($query) or die("Query failed : " . mysql_error());
- }
- function insert_images_loveplanet($link,$big_image,$small_image)
- {
- $link = mysql_real_escape_string($link);
- $big_image = mysql_real_escape_string($big_image);
- $small_image = mysql_real_escape_string($small_image);
- $query = "
- INSERT
- INTO
- `loveplanet_images`
- VALUES
- (default,
- '$link',
- '$big_image',
- '$small_image');";
- mysql_query($query) or die("Query failed : " . mysql_error());
- }
- }
- ?>
Add Comment
Please, Sign In to add comment