I found a problem in the eMule Light template. So basically what I did was testing some other stuff and when randomly clicking through the windows I figured out that the search results were not showing properly. So I did some research and I figured out it basically is because the eMule Light template requires one parameter less in it's creation. The major problem to fix this is that - unless I overlooked something - there is no way to distinguish the light from the normal template. So I just made a quick hack in the template so none of the eMule code needs to be touched. Here it goes:
The line should be right after:
<--TMPL_SEARCH_RESULT_LINE--> <tr>
Line in the normal eMule template (just so you can view the cause yourself):
<td class="search-line-left"><table cellspacing="0" cellpadding="0" border="0" valign=middle class="search-line"><tr><td background="l_sources_%s.gif" width="16" height="16" style="background-position:center;background-repeat:no-repeat"><a href="#" onmouseover="searchmenu(event,'%s')" onmouseout="delayhidemenu()"><img src="is_%s.gif"></a></td><td> <img src="filetype_%s.gif" align="middle"></td><td> </td>
Line in the distributed eMule Light template:
<td class="search-line-left"><table cellspacing="0" cellpadding="0" border="0" valign=middle class="search-line"><tr><td background="l_sources_%s.gif" width="16" height="16" style="background-position:center;background-repeat:no-repeat"><img src="is_%s.gif"></td><td> <img src="filetype_%s.gif" align="middle"></td><td> </td>
Fixed line for eMule light template:
<td class="search-line-left"><table cellspacing="0" cellpadding="0" border="0" valign=middle class="search-line"><tr><td background="l_sources_%s.gif" width="16" height="16" style="background-position:center;background-repeat:no-repeat"><!-- %s --><img src="is_%s.gif"></td><td> <img src="filetype_%s.gif" align="middle"></td><td> </td>
What I am basically doing is adding the parameter as a comment to the HTML code which is not exactly nice and saving us any traffic but it's still better than having a screwed up interface, IMO.
Addition 1:
Doing some more research, testing and coding I figured out there was a problem with the friend menu in the WebInterface. The friend menu is showing in the upload list and the queuelist but it is not showing in the banned list and the friends list. Now, there is nothing wrong with it not being shown in the banned list because those clients are generally untrustworthy. It is a different matter for the friends list because without being able to use this menu in the friends list we can remove friends only when they pop into the upload. So what needs to be done to enable the friend menu in the friends list? Simple, see below:
if(pThis->m_Params.bShowUploadQueueFriend) { Out.Replace(_T("[UploadQueueFriend]"), pThis->m_Templates.sTransferUpQueueFriendShow); Out.Replace(_T("[UploadQueueFriendList]"), _GetPlainResString(IDS_IRC_ADDTOFRIENDLIST)); CString sQueueFriend; OutE = pThis->m_Templates.sTransferUpQueueFriendLine; OutE.Replace(_T("[admin]"), (bAdmin) ? _T("admin") : _T("")); // Show friend menu in Friendlist of Webinterface [Stulle] - Stulle for(int i = 0; i < QueueArray.GetCount(); i++) { TCHAR HTTPTempC[100] = _T("");
You can find the appropriate line just searching for the tag "Show friend menu in Friendlist of Webinterface [Stulle] - Stulle" above.
Have fun with this,
Stulle
This post has been edited by Stulle: 21 November 2009 - 06:21 PM