621
liomj
Re: My overloads of the templates search.tpl and userinfo.tpl
  • 2021/10/27 7:19

  • liomj

  • Just popping in

  • Posts: 80

  • Since: 2012/4/10


Looking Good alain...nice



622
Mamba
XoopsMembers 1.04 Beta 2
  • 2021/10/26 8:09

  • Mamba

  • Moderator

  • Posts: 11374

  • Since: 2004/4/23


Resized Image


XoopsMembers 1.04 Beta 2 released for testing/contributions!

XoopsMembers is members search module for the User side.

DOWNLOAD: https://github.com/mambax7/xoopsmembers/releases

FORK:https://github.com/mambax7/xoopsmembers/

ISSUES/BUGS: Please report all issues on GitHub

REQUIREMENTS:
- XOOPS 2.5.10
- PHP 7.3+

It was tested on PHP 8.011 and PHP 8.1 RC-4
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



623
alain01
Re: Most current Xoops 2.5.11
  • 2021/10/25 7:48

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Hey,
you can change this jgrowl redirection, here:

/modules/system/admin.php?fct=preferences&op=show&confcat_id=1#redirect_message_ajax1



624
dejadingo
Re: Most current Xoops 2.5.11
  • 2021/10/23 20:58

  • dejadingo

  • Just popping in

  • Posts: 71

  • Since: 2004/10/22


I'm still slogging through the non-trivial changes to update the various templates to use Bootstrap 5 syntax for Forms. I decided to take a break and see what I could do with redirect notifications to eliminate the need for jQuery in my themes since Bootstrap 5 no longer depends on it.

I was a bit disappointed that I could not find a way to override a core event with my own code, but I have published an initial version of a module, XoopsGrowl, which can be used in a Bootstrap 4.x or 5.x theme (using trivial core hacks) to replace the old Xoops template based redirect notification with a JavaScript only implementation using Bootstrap Alerts.

This is my first submission, so feel free to say if there is something I should be doing differently. Also, feel free to incorporate this into the core at your discretion, or ask me to create a pull request making this a selectable option along with jGrowl in the System Preferences.



625
alain01
My overloads of the templates search.tpl and userinfo.tpl
  • 2021/10/22 12:48

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


I just finalized the overload of the templates search.tpl (Module system) and userinfo.tpl (Module profile).

- I added an "automatic" image overload mode.
If image overloading is present then use it otherwise use the default image

- I modernized the page with a presentation by module in cards
I also changed the location of some elements in order to have an optimal reading

- I replaced "<< Previous Next >>" with nice buttons.
They are now always visible and are simply disabled if the Next or Previous page does not exist

- I also optimized the width and so now the display is responsive.

Links :
Search:
https://www.monxoops.fr/search.php?query=xswatch4&action=results&lang=english
Userinfo :
https://www.monxoops.fr/modules/profile/userinfo.php?uid=2&lang=english

Please leave your comments and suggestions.

Finally, once completed, I could propose a Pull Request of these 2 templates in the xswatch4 theme in the core



626
alain01
Re: Overload the images on the search.php page
  • 2021/10/21 7:37

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Ok, so much the better, this solution was my preference.
Thank you for this information on good practices



627
Mamba
Re: Overload the images on the search.php page
  • 2021/10/21 7:33

  • Mamba

  • Moderator

  • Posts: 11374

  • Since: 2004/4/23


Always choose readability!!!

Or you will come back few months later and will waste a lot of time trying to understand what you've written!
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



628
alain01
Re: Overload the images on the search.php page
  • 2021/10/21 6:58

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Ok,
So, last question

The result is same but I want to know if a solution is better:

Readable test:
<{if file_exists($path_image_full_overloaded)}>
    <
div class="d-inline"><img src="<{$url_image_overloaded}>" title="<{$data.image_title}>" alt="<{$data.image_title}>"/> <a href="<{$data.link}>"><{$data.link_title}></a></div>
 <{else}>
    <
div class="d-inline"><img src="<{$data.image_link}>" title="<{$data.image_title}>" alt="<{$data.image_title}>"/> <a href="<{$data.link}>"><{$data.link_title}></a></div>
<{/if}>

or
Condensed test :
<div class="d-inline">
    <
img src=<{if file_exists($path_image_full_overloaded)}>"<{$url_image_overloaded}>"<{else}>"<{$data.image_link}>"<{/if}> title="<{$data.image_title}>" alt="<{$data.image_title}>"/> <a href="<{$data.link}>"><{$data.link_title}></a>
    </
div>



629
Mamba
Re: Overload the images on the search.php page
  • 2021/10/21 1:24

  • Mamba

  • Moderator

  • Posts: 11374

  • Since: 2004/4/23


Congratulations!!!

I glad to hear that it all worked out for you!!!
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



630
alain01
Re: Overload the images on the search.php page
  • 2021/10/21 0:38

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Yesssssssssssssssssssss §
I found it !

Thank you zyspec for your explanation and Mamba for your examples and links.

I found a solution with paramaters, no hard coded.
It was hard for me but it works.
Code :

<{foreach item=data from=$search.module_data}>

    <{
assign var="url_image_overloaded" value=$xoops_imageurl|cat:$data.image_link}>
    <{
assign var="path_image_begin_overloaded" value=$xoops_rootpath|cat:"/themes/"|cat:$xoops_theme}>
    <{
assign var="path_image_full_overloaded" value=$path_image_begin_overloaded|cat:"/"|cat:$data.image_link}>

    <{if 
file_exists($path_image_full_overloaded)}>
        <
img src="<{$url_image_overloaded}>" alt="<{$data.image_title}>"title="<{$data.image_title}>"> <a href="<{$data.link}>"><{$data.link_title}></a>
    <{else}>
        <
img src="<{$data.image_link}>" title="<{$data.image_title}>" alt="<{$data.image_title}>"/> <a href="<{$data.link}>"><{$data.link_title}></a>
    <{/if}>
    <
br />
<{/foreach}>




TopTop
« 1 ... 60 61 62 (63) 64 65 66 ... 29424 »



Login

Who's Online

173 user(s) are online (90 user(s) are browsing Support Forums)


Members: 0


Guests: 173


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Jun 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits