Debugging card generator

You hit this file from the front end
Listing ID is: 999 - which is there(!), not empty and numerical
Setting security _GET whitelist: ('id','lang','header','size','sticker','extended','password','feature')
No lang is set so defaulting to _en_GB
Size is set to:
Feature is set to:
Eco-sold is set to:

Setting some basic variables

$siteurlhttps://www.sapphireproperties.co.uk
$basepath/var/www/vhosts/sapphireproperties.co.uk/httpdocs
$template_name (as constructed from db set name, plus any other parameters)sapphire
Because we have a lang set, I have reconstructed the siteurl (for the QR mostly) to: https://www.sapphireproperties.co.uk
Query to get class name succeeded - It's: For sale
Query to get property details succeeded

Starting descriptions

Let's have a closer look at the EN description BEFORE processing:

<p>Lovely modern ground floor and top floor apartments with communal pool walkable to the beach.</p>

<p>These lovely apartments have a spacious lounge with dining area, large kitchen with base and wall units cooker, hob and extractor, three&nbsp;double bedrooms with fitted wardrobes one of which is en-suite and a family bathroom. &nbsp;The ground floor apartments come with private front and rear&nbsp;gardens, the front garden having a&nbsp;terrace that is accessible from&nbsp;the lounge. &nbsp;The upper floor apartments have a balcony terrace&nbsp;which is also accessible from the&nbsp;lounge&nbsp;and a large 66m2 solarium with electricity and water point great for entertaining, enjoying the sun and the views.</p>

<p>The properties benefit from fitted wardrobes, pre installation for air-con in lounge and bedrooms, shutters on all bedroom and balcony windows, tilt and turn windows in the bathroom&nbsp;and much more.</p>

<p>The large&nbsp;communal gardens incorporate a swimming pool, childrens pool,&nbsp;childrens play area and adults circuit with biohealth gym machinery.&nbsp;</p>

<p>These apartments are ideally situated in Pilar de la Horadada&nbsp;walkable to all amenities, bars, shops and restaurants&nbsp;and are just a short&nbsp;walk to the beach.</p>

<p>Alicante airport can be reached within&nbsp;45 minutes&nbsp;and Murcia airport is just a short 15 minute drive away.</p>

<p>&nbsp;</p>

<p>&nbsp;</p>

...and AFTER processing:

Lovely modern ground floor and top floor apartments with communal pool walkable to the beach. These lovely apartments have a spacious lounge with dining area, large kitchen with base and wall units cooker, hob and extractor, three double bedrooms with fitted wardrobes one of which is en-suite and a family bathroom. The ground floor apartments come with private front and rear gardens, the front garden having a terrace that is accessible from the lounge. The upper floor apartments have a balcony terrace which is also accessible from the lounge and a large 66m2 solarium with electricity and water point great for entertaining, enjoying the sun and the views. The properties benefit from fitted wardrobes, pre installation for air-con in lounge and bedrooms, shutters on all bedroom and balcony windows, tilt and turn windows in the bathroom and much more. The large communal gardens incorporate a swimming pool, childrens pool, childrens play area and adults circuit with biohealth gym machinery. These apartments are ideally situated in Pilar de la Horadada walkable to all amenities, bars, shops and restaurants and are just a short walk to the beach. Alicante airport can be reached within 45 minutes and Murcia airport is just a short 15 minute drive away.
No ES desc detected
No FR desc detected
No NL desc detected
No RU desc detected
No SV desc detected

Checking for two types of special English print desc (print, or short)..., that would trump the desc above...

No special print_desc was found
No special print_desc_es description was found

Checking prices

We have the current price (229900) - Checking for old prices...

The highest retrieved by the $listing->get_highestPrice() function is: 229900


Checking features

We have features so let's process them:

Exploded and sorted to

Array ( [0] => Close to amenities [1] => Fitted wardrobes [2] => Front balcony [3] => Pre-Installation for Air-con [4] => Short drive to beach [5] => Solarium [6] => Unfurnished [7] => Walking distance to bars [8] => Walking distance to beach [9] => Walking distance to restaurants [10] => Walking distance to shops )

That's 11 features

Here's a simple comma separated list in case you need it for the template... ... Close to amenities, Fitted wardrobes, Front balcony, Pre-Installation for Air-con, Short drive to beach, Solarium, Unfurnished, Walking distance to bars, Walking distance to beach, Walking distance to restaurants, Walking distance to shops

... and fancier, split into three equal columns:

Array ( [0] => Close to amenities [1] => Fitted wardrobes [2] => Front balcony [3] => Pre-Installation for Air-con )
........................
Array ( [0] => Short drive to beach [1] => Solarium [2] => Unfurnished [3] => Walking distance to bars )
........................
Array ( [0] => Walking distance to beach [1] => Walking distance to restaurants [2] => Walking distance to shops )

So col 1 looped is:

  • Close to amenities
  • Fitted wardrobes
  • Front balcony
  • Pre-Installation for Air-con

  • So col 2 looped is:

  • Short drive to beach
  • Solarium
  • Unfurnished
  • Walking distance to bars

  • So col 3 looped is:

  • Walking distance to beach
  • Walking distance to restaurants
  • Walking distance to shops


  • Checking images

    Running query to see if this listing has a pdf_images_order field

    ...which it does NOT, so we'll just use SQL to get the first six images like normal

    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0001_00000.jpg
    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0016_00000.jpg
    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0004_00000.jpg
    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0019_00000.jpg
    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0005_00000.jpg
    • [Internal listing so using large]: https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0015_00000.jpg

    • NOTE: images.upload.inc.php is set to use Amazon S3 in configuration
    • S3 class successfully included

    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0001_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0001_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0001_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0001_00000.jpg,wb
    • fwrite the file with: Resource id #24, $imagecontent (Massive long string! lol
    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0016_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0016_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0016_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0016_00000.jpg,wb
    • fwrite the file with: Resource id #26, $imagecontent (Massive long string! lol
    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0004_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0004_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0004_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0004_00000.jpg,wb
    • fwrite the file with: Resource id #28, $imagecontent (Massive long string! lol
    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0019_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0019_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0019_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0019_00000.jpg,wb
    • fwrite the file with: Resource id #30, $imagecontent (Massive long string! lol
    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0005_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0005_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0005_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0005_00000.jpg,wb
    • fwrite the file with: Resource id #32, $imagecontent (Massive long string! lol
    • Let's download: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0015_00000.jpg - Local check says we do NOT have that file
    • allow_url_fopen is available so using file_get_contents to get https://s3.amazonaws.com/clients.sapphire.listingphotos/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0015_00000.jpg
    • We received a good image, at least $imagecontent is not false!
    • Arrived at the saving part ready to use name: 999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0015_00000.jpg
    • fopen the file: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/images/listing_photos/temp/999_modern_design_apartments_with_communal_pool_walkable_to_the_beach_higuericas_costa_tipo2.0015_00000.jpg,wb
    • fwrite the file with: Resource id #34, $imagecontent (Massive long string! lol

    Grabbing the template at: templates/tpl.window_card_sapphire.php
    Template included OK

    Checking cache for filename: /var/www/vhosts/sapphireproperties.co.uk/httpdocs/pdf/pdf_cache/SAPP-1556-RM.pdf

    File does not exist in cache

    Checking SESSION for UserID - apparently not set?!


    You did not arrive from admin so the final header would be: /pdf/pdf_cache/SAPP-1556-RM.pdf
    Logging message to general log: "Printed window card for Ref: SAPP-1556-RM (ID 999) and sending the $userID: "
    Finished in 5.740 seconds
    Exiting due to debug true (ie not returning the pdf!)