Changeset 310 for trunk/aktuality/import_obec_hovezi.php
- Timestamp:
- Feb 6, 2011, 7:07:14 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/aktuality/import_obec_hovezi.php
r306 r310 20 20 $Date = $node->getElementsByTagName('pubDate')->item(0)->nodeValue; 21 21 22 $Title = $Database->real_escape_string($Title);23 22 $Description = strip_tags($Description); 24 23 $Description = str_replace("\r", '', $Description); 25 24 $Description = str_replace("\n", '<br>', $Description); 26 $Description = $Database->real_escape_string($Description);27 $Link = $Database->real_escape_string($Link);28 25 //if(($CommaPos = strpos($Date, ',')) !== FALSE) 29 26 // $Date = substr($Date, $CommaPos + 1); … … 31 28 32 29 33 $DbResult = $Database->select('News', 'Id', '(`Title`="'.$ Title.'") AND (`Category`='.$Category.') AND (`Content` = "'.$Description.'") AND (`Link` = "'.$Link.'")');30 $DbResult = $Database->select('News', 'Id', '(`Title`="'.$Database->real_escape_string($Title).'") AND (`Category`='.$Category.') AND (`Content` = "'.$Database->real_escape_string($Description).'") AND (`Link` = "'.$Database->real_escape_string($Link).'")'); 34 31 //echo($Database->LastQuery); 35 32 if($DbResult->num_rows == 0)
Note:
See TracChangeset
for help on using the changeset viewer.