aRo` automating your e-commerce

This blog has been neglected due to the success of Solidshops.com
14Sep/07

automatically resize iframe height depending on content

You can use this javascript function to resize the height of your iframe depending on the size of your parent page.

JAVASCRIPT:
  1. <script language="JavaScript">
  2. function iFrameHeight() {
  3. if(document.getElementById &amp;&amp; !(document.all)) {
  4. h = document.getElementById('main').contentDocument.body.scrollHeight;
  5. document.getElementById('main').style.height = h + 100;
  6. }
  7. else if(document.all) {
  8. h = document.frames('main').document.body.scrollHeight;
  9. document.all.main.style.height = h + 100;
  10. }
  11. }
  12. </script>

Popularity: 35% [?]

Filed under: javascript 12 Comments
13Sep/07

how to manage feeds between a pda and a computer

overview.png I have been searching for an RSS Reader that integratis with my PDA(Pocket PC).Finally i found RSS Popper wich integrates with MS Outlook.The feeds can be browsed as emails.A benefit from RSS Popper is that you even can fetch the webpage when the RSS feed only offers partial feeds.

But the main reason why i use RSS popper is that it can synchronize messages with my PDA over Active sync.

detail.png

Popularity: 3% [?]

Filed under: rss, software No Comments
11Sep/07

Gorilla Ad for Cadbury Dairy Milk


Gorilla Ad for Cadbury Dairy Milk
Uploaded by pubard1

Popularity: 3% [?]

Filed under: marketing No Comments
11Sep/07

getting your own .htaccess code in combination with wordpress

Just a quick not on mod_rewrite & wordpress.

If you want to write your own .htaccess code in combination with wordpress you have to put it above the default wordpress code.

<ifmodule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^arolabs\.com$ [NC]
RewriteRule ^(.*)$ http://www.arolabs.com/$1 [R=301,L]
</ifmodule>
# BEGIN WordPress
<ifmodule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</ifmodule>
# END WordPress

Popularity: 3% [?]

Filed under: php No Comments
8Sep/07

download a file from an ftp server to your webserver

I have several niche price comparison sites where i need to update my productlist on a regular basis. When a merchant delivers his datafeed from his webserver(http://domain.com/feed.csv) you can use php's filecopy function.

Other merchants only offer an option to fetch there datafeed from an FTP server(ie shareasale merchants). This is where the code below offers the perfect solution.

ASP:
  1. $ftp_server = "ftp.domain.com";
  2. $ftp_user_name = "";
  3. $ftp_user_pass = "";
  4.  
  5. $local_file = "download.txt"; //local path
  6. $server_file = '/del/todo.txt';//path on ftp server
  7.  
  8. $conn_id = ftp_connect($ftp_server);
  9. $login_result = ftp_login($conn_id, $ftp_user_name, $ftp_user_pass);
  10. ftp_pasv($conn_id, TRUE);//set passive mode
  11.  
  12. if ((!$conn_id) || (!$login_result)) {
  13. echo "An error occured while connecting to $ftp_server with user: $ftp_user_name.&lt;br /&gt;";
  14. exit;
  15. } else {
  16. echo "Connected to $ftp_server successfully with user: $ftp_user_name.&lt;br /&gt;";
  17. }
  18.  
  19. $download = ftp_get($conn_id, $local_file , $server_file , FTP_ASCII);//the file download
  20.  
  21. if (!$download) {
  22. echo "An error occured while downloading the file";
  23. } else {
  24. echo "Download completed succesfully";
  25. }
  26.  
  27. ftp_close($conn_id);

You only whant to use the passive mode when you get an "illegal port command" error.

ASP:
  1. ftp_pasv($conn_id, TRUE);//set passive mode

Popularity: 2% [?]

Filed under: php No Comments