FreiChat related discussions
problem with custom theme and select smiley image in chatroom

Hi
I use this nice plugin on Elgg. I create a new theme for it and I have a problem in chatroom. The frei_smiley_chatroom_select image that is for select and sending a smiley in chatrooms can not load. The URL of the image is wrong and the problem is in the image name. It has the full URL onto the theme directory but it has no image name at the end of the URL. I think the problem is raised in FreiChat.make_url function that can not return right URL.
The URL is like this: "http://localhost/Elgg/web/mod/chat/vendors/freichat/client/jquery/freichat_themes/Test/"

Hi I use this nice plugin on Elgg. I create a new theme for it and I have a problem in chatroom. The frei_smiley_chatroom_select image that is for select and sending a smiley in chatrooms can not load. The URL of the image is wrong and the problem is in the image name. It has the full URL onto the theme directory but it has no image name at the end of the URL. I think the problem is raised in FreiChat.make_url function that can not return right URL. The URL is like this: "http://localhost/Elgg/web/mod/chat/vendors/freichat/client/jquery/freichat_themes/Test/"

We have not yet updated the theme maker with the latest CSS/HTML from FreiChat 7.2 . We will be updating it in our next release .

In concern for your problem , we tried making a new test theme with the help of the theme maker , but we could not reproduce your problem.
So can you tell us exactly at what change did you get this problem or any steps that will enable us to reproduce the problem here, so that we will be able to solve it .

We have not yet updated the theme maker with the latest CSS/HTML from FreiChat 7.2 . We will be updating it in our next release . In concern for your problem , we tried making a new test theme with the help of the theme maker , but we could not reproduce your problem. So can you tell us exactly at what change did you get this problem or any steps that will enable us to reproduce the problem here, so that we will be able to solve it .
Necessity is the mother of all inventions!

I don't know what is the reason and in which change step the problem occurred. I create my theme on the previous version of the freichat and just copy and paste that theme here and change theme in-use in the admin settings. There were some problem like $freichat_theme variable that is changed to $config->freichat_theme. I make these changes manually and all images load completely but the problem make me sad. Temporarily I change the javascript code that generate the URL of the smiley_chatroom.png image and manually add the file name at the end of the URL and the problem solved but I can't understand the main reason of the problem.
Here is the firebug error log content: Failed to load resource: the server responded with a status of 403 (Forbidden). This error is show for incomplete URL generated by the script.

I don't know what is the reason and in which change step the problem occurred. I create my theme on the previous version of the freichat and just copy and paste that theme here and change theme in-use in the admin settings. There were some problem like $freichat_theme variable that is changed to $config->freichat_theme. I make these changes manually and all images load completely but the problem make me sad. Temporarily I change the javascript code that generate the URL of the smiley_chatroom.png image and manually add the file name at the end of the URL and the problem solved but I can't understand the main reason of the problem. Here is the firebug error log content: Failed to load resource: the server responded with a status of 403 (Forbidden). This error is show for incomplete URL generated by the script.

The smiley_chatroom.png is a image that was added in the newer version , so since you copy pasted the theme from an old version , there was no definition for this image in your old theme.

What you can do is , open the argument.php , of the "basic" theme of the current(latest) version of FreiChat and copy paste the line that defines this image in the argument.php and argument_def.php files present in your copy-pasted theme .
The line should read something like this

$smiley_chatroomimg = 'smiley_chatroom.png';


Also , to make sure that this works ,remove any changes you have done to FreiChat.make_url()

The smiley_chatroom.png is a image that was added in the newer version , so since you copy pasted the theme from an old version , there was no definition for this image in your old theme. What you can do is , open the argument.php , of the "basic" theme of the current(latest) version of FreiChat and copy paste the line that defines this image in the argument.php and argument_def.php files present in your copy-pasted theme . The line should read something like this <code>$smiley_chatroomimg = 'smiley_chatroom.png';</code> Also , to make sure that this works ,remove any changes you have done to FreiChat.make_url()
Necessity is the mother of all inventions!

Hi
That was the exact solution. It is work like a charm.
Thanks for your powerful plugin and nice support.

Hi That was the exact solution. It is work like a charm. Thanks for your powerful plugin and nice support.
120
4
0
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft