Elxis CMS Forum

Support => General => Topic started by: epaz on February 21, 2008, 16:02:51

Title: User Profile
Post by: epaz on February 21, 2008, 16:02:51
If a user edits his profile, values for the "Website" and "ICQ" are not saved in database. Is there any trick with these fields? I guess not. Seams to be a bug....

More over if I change these values directly using phpMyAdmin, when entering the user data entry from the administration console, though they initially exist, if I make some changes (to other fields) and post to database these 2 field values are lost (they are converted to NULL).
Title: Re: User Profile
Post by: datahell on February 23, 2008, 20:00:40
I don't think there is a bug as we already use them at elxis-downloads.com website with no problem.
I check it right now and I will post a report in a while.

EDIT:
Checked, no problem found.

Please check your Elxis file-system with Updiag to ensure that you have an authentic Elxis installation.
https://www.elxis.org/guides/general-guides/check-elxis-filesystem-with-updiag.html

If all files are ok re-try.
If the problem persists you can send me user account info to check it.
Title: Re: User Profile
Post by: epaz on February 25, 2008, 11:26:59
Well, reading the source code I have discovered the following:

1. What the user enters in the WebSite field will not be save unless the http:// prefix exists. So a website like www.mywebsite.xyz is not an acceptable one but http://www.mywebsite.xyz is. I have not problem with this kind of logic. Of course some specific need has enforced it. BUT it is cryptic and misleading. A user that makes a registration is supposed to supply this kind of information once. How is he supposed to know that particular peculiarity? Most of us type www.abc.xyz and then hit <enter> and we surf....
Since you want elxis to be a professional piece of work you should treat the user like being a lady. Nowadays what makes the difference is elegance. It would be more elegant if you made a search about whether http:// prefix exists and if not, add it.
The rule is: Respect user data.

2. About ICQ now. The field accepts only numeric values (no alphanumeric characters allowed). Is this correct? Of course it is. Source code says so. I must admit that I had no idea about ICQ. A user that is familiar with it would have supplied an appropriate input. So consider the ICQ part of the case, closed.

Now, to updiag tool. I have downloaded that hash files and tried to run the tool. I submit a screen shot that shows 5 files as "need update". These are the files that I have added some code to support a special feature. My problem (as you will see) is that the scan cannot exceed the period of 60 seconds. Is there any way that I can change this? I am running elxis on a latest xampp installation, on my usb stick.

Thanx
Title: Re: User Profile
Post by: datahell on February 25, 2008, 14:50:23
About the http:// prefix: OK, this is easy to be changed.
Code: (php) [Select]
<?php 
if (!preg_match(&#39;/^(http\:\/\/)/&#39;, $row->website)) {
$row->website = (trim($row->website) != &#39;&#39;) ? &#39;http://&#39;.$row->website : &#39;&#39;;
}
?>

About Updiag: Updiag needs more cpu power than a usual script as it checks about 3500 files. Increase the allocated PHP memory in your php.ini to 16MB or more.