Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

TobiasKnudsen

Members
  • Joined

  • Last visited

  1. http://view.qrdetector.dk/test.xml Sorry I added a space at the end of the link! Should work now
  2. I've uploaded a sample of the XML to one of my test domains: You can view it here: http://view.qrdetector.dk/test.xml It's a complete database of all the cars in Denmark which is why the main file is 56 GB. I need to extract some of the information like <ns:RegistreringNummerNummer> and <ns:SynResultatStruktur> for each of the <ns:statistik>. Problem is that not all of them have <ns:SynResultatStruktur> and some of them have lots of information between this isnt relevant for my project. A solution would be to store only one <ns:statistik> in memory, search through this and add the needed information to my database then remove from memory and repeat for next <ns:statistik> element
  3. I had a program splitting in into smaller parts over night, but now I'm left with 11500 files all with 750 elements each ~ 5-8 MB each. How would you do this?
  4. In php i've heard about eventbased XML parsers which wont store the entire file in memory, but will look at each element at a time and then go through all the elements in the XML file.
  5. Hello WebDesignerForum, I've got a huge XML file. Currently it's about 56 GB and increasing size about 250 MB / week. I don't need all the elements in the XML file, and not all the elements contains the same information. How can I stream this file and check if a specific child exist and then insert it to my database, and if not then go for next element? I've tried searching for PHP scripts, VB.net and C# code, so i accept any help in these languages Thanks
  6. I found some str commands and got it to work with my database. Here is my code, if anyone has the same problem and could use my solution. Thanks for your help. // Database Connection require_once('Connections/DatabaseCon.php'); //Get the html code from the link in my databse $html = file_get_contents($row_Recordset1['url']); //Then I remove all new lines because this gave me problems with the search later. $var = str_replace(array("\r","\n"),"",$html); //Then I define my 2 search variables from my database $tag_begin = $row_Recordset1['search1']; $tag_end = $row_Recordset1['search2']; $begin = strpos($var, $tag_begin)+strlen($tag_begin); $end = strpos($var, $tag_end); $length = $end-$begin; $result = substr($var, $begin, $length); echo $result; This works when the search strings are unique on the html page or the first match Hope this can help some of you! Good Luck
  7. Hello Webdesignerforum.. I'm currently working on extracting specific parts from a different website. My plan is to get the html source code and extract the part with preg_match I need. This is what i currently have. $str = htmlspecialchars(file_get_contents('http://www.example.com/')); $start = '<title>'; $end = '</title>'; preg_match('/'.$start.'(.*?)'.$end.'/', $str, $match); echo $match[1]; My search strings $start and $end are both part of the source code and can consist of all the normal symbols you might find in a html code like ' " , < > / : ; so i guess i have to avoid these symbols as much as possible. If i search like this: $str = htmlspecialchars(file_get_contents('http://www.example.com/')); $start = 'title'; $end = 'title'; preg_match('/'.$start.'(.*?)'.$end.'/', $str, $match); echo $match[1]; this returns: >Example Domain</ But when i add </> i get into trouble. I'm not an expert with preg_match and I don't know if this is the best way to grab the data. Hope you can help me! Any comments can be a big help!
  8. Hello WebDesignerForum I'm have a problem with updating data in my database. Lets say I have a database like this: Database Name: 'Companies' Columns: 'Company' | 'Address' | 'ZipCode' | 'City' | 'Lng' | 'Lat' | 'Rating' | 'Price1' | 'Price2' I get the data for my database from 2 sources. The columns company, address, zipcode, city, lng, lat and rating I extract from a table on a different website, where i grab the html code and run a macro which removes all the unwanted code. I'm left with a textfile where each row is a different company and each column is separated by a semicolon. I then save this as a .csv file and import this to a new table in my database. Now I need to compare the two tables and check if my current Rating fits the new data I just imported. How do I do this? Also the new data might contain new companies, so if this is true it needs to add the new company to the 'Companies' table. I've been looking into the join command, but it seems as if the join command only works when i have the same companies in both tables. I guess i need to merge the 2 tables and if some of the table data is in the new table it needs to replace the current data. Hope you understand my problem. Thanks!
  9. Hej Nilervision, Tusind tak - utroligt der allerede er en som har svaret. Hjemmesiderne jeg vil hente data fra har ikke API tilgængeligt. Er det sådan vi kan skrives ved over email, har nogle spørgsmål og tror bedre jeg kan forklare det med et eksempel. - Tobias
  10. Hello, I'm working on a small project, where I want to compare prices of different sellers. I have about 450 sellers with different prices and websites. I need to make a script, which can go through each of the sellers websites and grab the price of their product and store it in a MySQL database on my server. How do I do this? Lets make an example. Seller one's website link is: example1.com. On this page there are 3 tables. The price I'm looking for is in the 2nd table 3rd row, 2nd cell. Seller two's website link is: example2.com. On this page there are only 1 table. The price I'm looking for is in the 1st table 2nd row 3rd cell. I would then create a database like this with all 450 sellers and the location of the price in the table, which I need. --------------------------------------------------------------------------------------------------- | Website link | Table Number | TR Number | TD Number | Price | --------------------------------------------------------------------------------------------------- | example1.com | 2 | 3 | 2 | 19.99 | --------------------------------------------------------------------------------------------------- | example2.com | 1 | 2 | 3 | 17.75 | --------------------------------------------------------------------------------------------------- The script then needs to go to the first website and check the 2nd table, 3rd row, 2nd cell and check if this value is equal to the current value of the database and then loop back and check the next price. Is this the way to grab the content of a specific TD on a different website, or do you have a better solution? Hope someone can help me. Any help is appreciated!
  11. Hello Im working on a website for a holiday house. I wanted to make a google steet view effect for each individual room, and i figured to do this with a 360 degree panorama picture of the room. It looks great but i was wondering how i could make it with drag and drop like this exsample: http://codecanyon.net/item/360-panoramic-viewer/full_screen_preview/2684810 I would also like an automatic version where i can place it as a background, where its position is moving so it's looks like you are looking around in the room. - Tobias
  12.    TobiasKnudsen reacted to a post in a topic: PLEASE REVIEW MY SITE NEED DIRECTION
  13. Hey, im working on with website where you can watch funny videos, and then i want to make a login with facebook, and then get permission to make a post, so when a user watch a video i want to post a link to the same video! How can i do this?! BTW my website is in php, so i would like to have it using the facebook php sdk?
  14. How can i create a view counter using my mySQL database, that will increase +1 everytime the page is refresed. I've created some, but it dont update the website when i refresh, but just shows a catched version! HELP ME
  15. Hello, I'm working on this website, with some videos, and i would like to have a login system, to give my visitors the ability to rate and comment the videos. I'm not very familiar with login systems, and that's why i'm trying my luck here. My big problem is remembering if the user is logged in or not. I've created a simple login, with a form and when you press login, it will run a php script and connect to a database and check if the username is correct. If it is then it will redirect to a login page, and else it will redirect to wronglogin. As i said then i dont think the problem is the login part, but if i login to the website, and then lets say i click on a link in the menu, then i would have to login again? How can i check if the user has logged in, even when i go to other pages on the website? I've searched the internet, and some say i have to use cookies, with the entered password and username, and then check on every page if the cookie password and username is == to the username and password in the database? This might work, but i dont believe this is the best way of doing it? Another solution i found was using php sessions, but i dont know anything about php sessions or cookies, so if the best solution is one of these too, then i would love to know which is better and maybe get some help! Maybe if none of them, then i ofcause would love some help anyways!! -Tobias

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.