Jump to content

quecoder

Members
  • Posts

    26
  • Joined

  • Last visited

    Never

Everything posted by quecoder

  1. IT WORKS ... Thank you effigy !!! Any one tries to use this regex, don't forget to use the proper encoding when saving the file ...( ex : UTF-8 )
  2. Hello How can I match Arabic letters , ... they are located between 0621 to 064A in the Unicode code points .. can I use \u or \x ? Using preg functions. . PCRE
  3. What is better ? http://www.regular-expressions.info/ or this book ? I want to be an expert in RegEx :)
  4. Hello , I have tried to learn more about them from the manual http://www.php.net/manual/en/book.stream.php But they don't explain any thing useful about them except how to use their functions .. Specially wrappers like php://input , or php://output ... I don't know what they mean or why should I use them ... And ofcourse , all other streams/wrappers are very obscure for me .. Where can I learn more about them in greater details ?? An ebook ? online tutorials *?? (*) tried to google it already .. but no useful result Thanks in advance
  5. Hello , I want to offer services for webmasters from within my website , let's assume the service is , their users can invite their friends to those webmaster websites using my service that let's the users to input their friends email addresses and type in a personalized invitation message and send it . what I did is , enabled these webmasters to put a link that opens a pop up window of a page in my website that shows the invitation form and users can send and then close the pop-up window to return to webmaster site. As I wanted to recognize these webmasters domain names , essentially to both send the invitation with the domain name to where users friends shall go when invited, and to know how much emails this domain has consumed because sending stmp emails are not free, so I should limit their quota to max 100 or so . I used a very basic function in php to recognize the webmasters by their domains: $url = $_SERVER['HTTP_REFERER']; $domain = parse_url($url); $domain = $domain['host']; if( substr($domain, 0, 4) == 'www.') { $domain = substr($domain, 4); } owner of this domain - $domain - ofcourse had been registered it in my website and I insert the required information in the database. I know that this is a very basic , but that is because I'm a newbie in PHP so I want to solve these problems : 1 - Webmasters can fake the Referrer address to gain extra messages sent by their users or to use my service when they are not registered at all . 2 - Using just this pop-up to provide my service doesn't let me know much information about the incoming request owner . 3 - How can I use this service to my benefit , or to even increase my PageRank ( does placing a pop-up window link of my website in different webmaster sites increase it ) ? (Sorry my English sucks)
  6. Hello , what is the difference between MySQL and MS SQL ,,, And how to connect a web site MySQL database in a local web server ( XAMPP ) with another windows application ( programmed by VB.NET )
  7. the problem has been solved .. thank you
  8. another demonstration: Changes are : room_id , Quantity for every record , but the same booking_time for every record of them ... this may consider unique for each customer because this timestamp is with seconds ...checkin and checkout may not be unique for sure .
  9. HI , I have a bookings table for hotel rooms reservations , a customer makes a reservation , for example , 2 double rooms and 1 family room .. for each room type ( double , family ) I insert one record in bookings that has the room id for this type and quantity ..so , if double room has an ID = 1 , and family ID = 2 , I place the following : booking_id cust_id room_id quantity checkin checkout booking_time Pay_due_amount 1 123 1 2 1205532000 1205618400 1205532000 600 booking_id cust_id room_id quantity checkin checkout booking_time Pay_due_amount 2 123 2 1 1205532000 1205618400 1205532000 600 pay_due_amount is the total payment for both rooms . so every thing is fixed except room_id , quantity . dates are of data type INT , I store the time stamp in them. Question is : when I query for his last five orders in his member area , ((( he may place another order after half an hour and the booking time will be changed for all records for this order ))) , how to distinguish between records and group the ones with same order together , like , to get all data with similar booking_time for that customer ( cust_id) ... is this right ?? and if yes , how to make it?
  10. ah !! but when grabbing product fields, splitting and inserting each product in a record ..i may come across another merchant with that specific product again , so how to deal with this ?? check if it exists first or else, make a new one ? or what did you mean ? and what is the structure of that merchant_product table ?
  11. but how to store 100+ IDs in the same record of the product , and how to , after that , query for these IDs when browsing by this product
  12. this will not work , I want to do this with the products , grabbing one product at time from the text file , searching for all possible merchants that shares this product , get their IDs , and insert these IDs as well as this product into a new record in Merchant_products .... Not vice versa , because two or more merchants may share two or more products .. and I want to browse by products
  13. please fenway , tell me one answer instead of asking questions that spanned to 2 pages..
  14. yes products are sperated by commas in the text file and also in the product field in merchants records .. ALL time
  15. can I make this as a PHP function that query for each product a list of merchant that have this product in their product field and increase the product table for every product one record with the product and the result of the query .. but how to search the database ,, !! this is the main question for this idea .. I don't know how to search it from within PHP
  16. yes I know that !!! :-\ I'm asking about how to make that while having 3000 products , and when inserting each in a single record , how to search for all merchants who sell this specific item and put them in another field in the products table .... any thing to automate this process ?
  17. I said , to click , just to simplify it .. anyway , I have all the merchants in records in a database already , each one in a separate record with it's own products field
  18. no , it's not in the database . I want to , for example , insert each product in a record but links to each merchant sell it ..so , when clicking in a product it shows me all merchants who sell it ...
  19. I want to let them search and browse merchants by products not only by merchants...
  20. a list ( in a text file ) of all the products starts from A to Z with no duplicates .. a merchant X can have product P1 , P2 and a merchant Y can have P1 , P90 , P100 from this list. the merchant list is already loaded with products ..
  21. Hello ! I have a big list of merchants ( 1300+ ) , each one has , website & address ...etc and his combination of products he is selling .. I got a unique list of products ( 3000+) that all merchants share .. some share ( provide ) 3 products , and up to 100.. I have the list of merchants stored properly in a MySQL database , but the problem is , the list of products is just a list of products ordered alphabetically .. **I want my visitors , besides browsing my list of merchants and read their data and products , to search , as well , for merchants by browsing these products keywords and when someone clicks on one , it shows him a list of merchants who provide this product ... Thanks alot
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.