How to modify object link of jcomment?



JComment is a big components for joomla, bothjoomla 1.5 andjoomla 2.5. It also means that it is so complicated.

Today, I want to change the object link of each comment. Because, each time, users click on this link, I want it open with a better link than jcomment did.But it's really hard to find out where it is. First I look at object.php of models folder, object.php of class folder in admin. Finally I know it is folder com_jcomment/plugins.

In this folder you have a list of components that jcomment integrated.

I, myself want to modify admanagers link, so I open com_adsmanager.plugin.php file.

In this file you 'll see a line like this:

1.$info->link = JRoute::_("index.php?option=com_adsmanager&view=details&id=" . $row->id . "&catid=" .$row->category . $Itemid);

This is the link of object, now, you can edit as you like.

Hope this is helpful for you.


[Read More...]


How to fix joomsocial core app does not display in sitebar position?



the new version of joomsocial has some error, and someone can not wait will be angry about it. I have write a new own application, and i want it displays in sitebar-top position. Although I choose the position is sidebar-top, or sidebar-bottom it's not display. After that, if i set it is not a core app, and user can cofig by their own app, it can display it these both position. I'm really disappointed.

In the internet, question about joomsocial is hard to find an answer. I decide to find out by myself. Finally I figure out why it's not display. when we set our apps to be core, that means that their positions become sidebar-top-core or sidebar-bottom-core or content-core, but in the view.html.php of profile and in template profile.index.php don't include them. Now I will show you how to fix it.

First, go to com_community/views/profile/view.html.php, find these code, and add the three new position: 'content-core', 'sidebar-top-core', and 'sidebar-bottom-core'

01.// Split the apps into different list for different positon
02.$appsInPositions = array();
03.foreach( $appData as &$app )
04.{
05.if( !in_array($app->position, array('content','content-core', 'sidebar-top','sidebar-top-core', 'sidebar-bottom','sidebar-bottom-core')) ) {
06.$app->position = 'content';
07.}
08.$appsInPositions[$app->position][] = $app;
09.}

then, add three more item in the code below:

1.$contenHTML['content'] = '';
2.$contenHTML['sidebar-top'] = '';
3.$contenHTML['sidebar-bottom'] = '';
4.$contenHTML['content-core'] = '';
5.$contenHTML['sidebar-top-core'] = '';
6.$contenHTML['sidebar-bottom-core'] = '';

and finally, you transfer it to template by these code:

1.->set ( 'contentcore' , $contenHTML['content-core'] )
2.->set ( 'sidebarTopcore' , $contenHTML['sidebar-top-core'] )
3.->set ( 'sidebarBottomcore' , $contenHTML['sidebar-bottom-core'] )
4.->set ( 'content' , $contenHTML['content'] )
5.->set ( 'sidebarTop' , $contenHTML['sidebar-top'] )
6.->set ( 'sidebarBottom' , $contenHTML['sidebar-bottom'] )

All things in view.html.php is done.


Now, please open the com_community/template/profile.index.php, find this code

1.echo $sidebarTop; ?>

and add this

1.echo $sidebarTopcore; ?>
2.echo $sidebarTop; ?>

and like others, we get this:

1.echo $sidebarBottomcore; ?>
2.echo $sidebarBottom; ?>

and

1.echo $contentcore; ?>
2.echo $content; ?>

Now you can try again and see how it runs. Hope this helpful for you.

[Read More...]


How to set order of module position in joomla 1.7 and joomla 2.5?



If people are too familiar withjoomla 1.5 , it is a bit difficult to set order of modules inJoomla 1.7 andjoomla 2.5. In the modules order position, we now can not enter number to set its order.

How to set order of these module?

Please click at Ordering, it will enable these inputs, and you now can enter the number of these modules like in below image:

We hope that this small tip help you reduce time of finding.

[Read More...]


A beautiful virtuemart module to display latest and feature products



Virtuemart is very powerful for shopping website. Almost joomla website, includejoomla 1.5 ,Joomla 1.7,joomla 2.5, now use it to show their products. Unlucky, its code is so complicated to understand on short time. If you want some changes in its display it is really difficult.

We recommend you a new virtuemart module of jw-extension.net which displays products in a special way that like no other modules before. It's like and a popup advertising module. When users browse your webiste, it 's display a popup contents product images, and its circle animation make they focus on it. User can click at image to see for details. You can config to display one time for a user, or many time after refresh or reload, and much more for you to modify its visual.

You can see demo at: demo jwscrollimagevirutemart

and download at: module jwscrollimagevirtuemart

If you have any question please let us know.

Hope this is helpful for you.

[Read More...]


How to add more ajax function in joomsocial?



Today I work with joomsocial ofjoomla 2.5. Joomsocial is a big commercial component, but we sometime have to edit it to fit our require. I has written a new form that let users transfer point from one to one. I try to write new ajax function but it meet some errors.

Firstly, I found the instruction in file jooms.ajax.js to call a new ajax function:

01.joms.ajax.call(sFunc, sArgs, settings)
02.joms.ajax.call('controller,function', [arg1, arg2] {
03.success: function(data) {
04.// What to do when the ajax call is successful
05.},
06.error: function(data) {
07.// What to do when the ajax call is not successful
08.// e.g. timeout, 404, 500, etc.
09.},
10.
11.// For more settings to fiddle with, look up jQuery.ajax() docs.
12.});

And then I write a function

01.function showform()
02.{
03.joms.ajax.call('profile,ajaxGetForm', [echo $userid?>], function(data)
04.{
05.console.log(data.url); // output http://www.jomsocial.com
06.console.log(data.caption); // output JomSocial
07.});
08.
09.}

and add a function ajaxGetForm in profile.php of controller.

but it just displays nothing.

then, i turn on firebug, move to console, I read that error is function not found. I thought that there must be a place for define these function. Finally i found it jax.community.php, and I add this line $jaxFuncNames[] = 'profile,ajaxGetForm'; in line175.

Finally, It run well. Now I have new function ajax in joomsocial. It is so good for us to develop more for joomsocial.

Hope that this is helpful for you.

[Read More...]


 

Link Liên kết

Thông tin liên hệ

YH: huonggiangdhtn
Skype: tthuonggiang
Return to top of page Copyright © 2010 | joomla extensions jw-extension.net