Support > cpg1.6 miscellaneous

thumbnail.php => blank page output

<< < (2/2)

ron4mac:
I thought about this more...

There are likely mysql calls in your curve derived themes.

In two locations in your theme.php file you need to make changes...

change:

--- Code: ---                if (mysql_num_rows($user_albums)) {
--- End code ---
to:

--- Code: ---                if ($user_albums->numRows() > 0) {
--- End code ---

and change:

--- Code: ---                if (mysql_num_rows($public_albums)) {
--- End code ---
to:

--- Code: ---                if ($public_albums->numRows() > 0) {
--- End code ---


You should really keep installed another standard theme that comes (and is updated) with CPG. It helps to identify theme problems when they occur.

moklein:
Since I am working with mysql I just changed 'mysql' to 'mysqli' and it all worked again
(or would changing it the way you described be better practice ?). I forgot to check for
updates in Curve and just reinstalled the old (responsive) version, would have taken me
ages to find this out since debug did not show any errors, you're a star, thanks very much
for the help :-).
kind regards,
Martin

ron4mac:
Even though it is working for you, changing it as you did is not the correct way to do it. It is passing mysqli a foreign object.

For best compatibility, change:

--- Code: ---    mysql_num_rows($xxxx_albums)
--- End code ---
to:

--- Code: ---    cpg_db_num_rows($xxxx_albums)
--- End code ---

Sorry ... I should have instructed you to use that method in the first place.

moklein:
See what you mean, changed all instances.
Thanks for all your help.
best wishes,
Martin

Navigation

[0] Message Index

[*] Previous page

Go to full version