21
birdseed
Re: Module development - AddElement
  • 2006/7/10 14:18

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi McNaz,

Quote:

Sorry but I have to disagree there. Especially the bit about "good style to get HTML out of the php files". It might have been good style ten years ago but we've (thankfully) moved on from the stone ages of PHP and HTML in one file.


Even today many PHP Newbie Tutorials use that approach and xoops1 still used it. Even in xoops2...have a look at the implementation of the comment system and tell me if this is how it should be.

I think we both want the same result. Well structured code. What I criticised in your post is that you see it too dogmatic by not using the XoopsForms because it would injure the MVC principle.
First, the basic MVC Approach is originally aimed at fat clients. In Web application, you can't adopt that at 100%, you can just do "something that looks like MVC".
Second, it isn't even said that XoopsForm injures the MVC principle. Prove it to me. ;)

In ASP.NET, you have something which is calles SqlDataSource. SQL Statements directly in the HTML Code! Ugly, you would think. But: The idea is from .NET 2.0 (2005 and not 1995) and it makes code development much faster for smaller applications. Although it hurts almost every principle of structured code. No matter, it works fine.

Quote:

I would imagine that Smarty templates consume less overhead due to the fact that Smarty caches and compiles php files. You also get the added bonus of not having HTML strewn all over your PHP file .


Ever had a look at a compiled result of a <{section}> Tag? Ever went into a function call of a runtime plugin with a debugger? Ever stepped though the instanciation process of a smarty template? The IS much overhead. Even with the compilation result.

greetings
birdseed



22
birdseed
Re: core 2.2.4: token system annoying
  • 2006/7/10 13:59

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

you haven't read my posting attentively. XOOPS security disallows the repeated sending of POST requests.

greets
bsm



23
birdseed
Re: Module development - AddElement
  • 2006/7/10 9:45

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

If you just want a simple answer form, use liaise or other modules. But you said you want to do your own module which looks like you have some custom stuff to do. So use Xoopsforms for that.

If you need highly flexible forms (e.g. with multiple colums) then you have to build your form with smarty from scratch.

greetings
bsm



24
birdseed
Re: core 2.2.4: token system annoying
  • 2006/7/10 9:07

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

The token system is there in order to avoid sending the same post request many times. It appears when you click on the "back" Button of your browser, what you shouldnt do on post requests already sent. I wouldn't completely deactivate it. Seems you use modules which have implementation problems with the XOOPS Token. You could simply comment out calls to the $xoopsSecurity class / check command on that specific page where it annoys you.

greetings
birdseed



25
birdseed
Re: Module development - AddElement
  • 2006/7/10 8:59

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

There is a certain runtime overhead in using the XoopsForms which would be still worse is they were implemented as smarty templates. So xoopsforms are quite as they should be. Remember that smarty tends to be slow because every template has to be loaded from the file cache, checked it if need compilation, a lot of smarty logic, the plugin loader.... I don't start to talk about what a <{section}> tag does and how plugins are executed if they are not compile-time plugins.

I think the code/presentation separation arguments from McNaz are more like "I am a programmer and I do it my way" than what is really necessary. Generally, it is a good style to get HTML out of the php files and encapsulate your business logic into classes, but to not using xoopsforms because of some misunderstood rules...nonono. Use them, they allow you a good programming style.

The XOOPS core is not always consistent, this is quite ugly but usual if code has grown over the time. The most important rule I learned from 3 years of XOOPS programming: Try to understand XOOPS and try to understand the concepts, but stay pragratically.

greetings
birdseed



26
birdseed
Re: Which PHP editors are best?
  • 2006/7/8 10:33

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

I don't think that PhpEclipse provides an integrated debugger. This is probably the best part of Zend Studio.

(available for Windows/Apache too...)

greetings
birdseed



27
birdseed
Re: xoops related gfx
  • 2006/7/7 22:10

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

I think you are quite talented, it look nice, but I can imagine that the XOOPS team will like something more conservative and "grounded", not so stylish and metal and bevels and stuff.

greetings
birdseedmusic



28
birdseed
Re: Which PHP editors are best?
  • 2006/7/7 22:02

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

Zend Studio is the best one. Install it under Linux (Suse 10, Fedora Core 5....) for best performance.

greetings
birdseed



29
birdseed
Re: Cannot log into own site.
  • 2006/6/28 12:21

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


You can login by going tohttp://my_xoops_url/userinfo.php

greetz
bsm



30
birdseed
Re: Special Ranks
  • 2006/6/27 8:35

  • birdseed

  • Just popping in

  • Posts: 59

  • Since: 2005/2/26


Hi

You have to change every template where The Rank is displayed.


<span style='<{if $comment.user.rank == "Moderator"}>blue<{elseif $comment.user.rank== "Admin">red(....)<{/if}>">
<{$comment.user.rank}>
</span>

comment.user.rank is just a suggestion. Please look at the template to find out the rank variable name in the context.

Other suggestion: Hack The getVar Function of the XoopsUser class.

greetings
birdseed




TopTop
« 1 2 (3) 4 5 »



Login

Who's Online

166 user(s) are online (100 user(s) are browsing Support Forums)


Members: 0


Guests: 166


more...

Donat-O-Meter

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

Latest GitHub Commits