Wappler pages inside cms

Hello,

I have seen that you have launched CRUD tables lately. So I am back, checking those new features. Is there a demo anywhere showing a table with inline edit?

My main question:

From what I understand, Wappler will create all needed files inside a folder, along with index.html.

Correct?

Is it therefore possible, to output the page using e.g. a simple Joomla 4 module. I need those pages on top of a CMS (in my case Joomla 4). This means I will need to connect to my live server mysql db, once files have been uploaded and also check e.g. for user_i9d of logged in Joomla user.

Could you give me a hint if wappler pages would work as stand alone pages and if those requirements (get user_id or check if user is logged in) can be dealt with easily using some custom code?

Thank you

Welcome back to Wappler!

Unfortunately I doubt you would have much success mixing Wappler and Joomla.

1 Like

Thank you.

May I ask…where do you see the problem?

I should be able to connect to the mysql database.

Another approach would be to either open index.html with a modal inside CMS (static onepager) or rebuild the basics of joomla theme header and footer - thefore use all wappler pages as stand alone pages.

Can’t I just use some simple php in order to “inject” my index.html wappler page inside a Joomla 4 page?

I could add scripts with header and/or footer of my Joomla theme.

Any thoughts on this appreciated.

No idea how Joomla works. I believe you are in a better situation to assess if you can do what you need. Wappler produces standard websites based on html, css and js. On the backend you can choose php and mysql is supported. If you can make all that work with Joomla then I don’t see any problem.

1 Like

There is no Wappler built tools to create tables with inline editing. A few people have found ways to build them but there is no such Wappler feature to build them for you.

In order to connect to your database, etc your page would have to be a php page not an html page. So this may cause conflicts with Joomla as you can only of course have one index page. Having said that, you can create pages with any name you like in Wappler. It doesn't have to be index.

Also, unless your Joomla templating uses Bootstrap, mixing platforms will cause you problems.

This will depend on how Joomla hashes passwords. I think you would need to create your login forms with Wappler to create the proper sessions that Wappler needs to get user ids from the database. At least I don't see a way that it would work.

I guess the best thing would be to try it out and see what happens. Be sure to back up first as Wappler will create many files and folders. :wink:

Do you have a sample page that I could try to inlcude with my Joomla 4 Module?
My trial with the new Wappler version has already ended.

Joomla 4 comes with Bootstrap 5.

If your CRUD tables can’t do inline editing, what can they do and how do we update (edit) rows?

  • Update with form in a new page?
  • Update in form below the record as child row?

Is there a feature list of some kind?

I would really like to see a simple CRUD example with all current features.

CRUD functionalilty isn't exactly built in. Wappler enables you to create whatever functionality you need. Eg you mention inline editing. You can incorporate this into your tables. There was a discussion about it which demonstrates the flexibility available if you use Wappler (and perhaps also the limitations, if you need a ready-made solution).

1 Like

A new page, or a modal or a data detail region. Really depends on your needs. If I have an edit that has a lot of data I use a new page. If it's only a few data points I use a modal.

1 Like

do you have a sample page which I could try to use with my simple joomla 4 module?

with a j4 module, there is a default.php file that outputs to the module position within the j4 template.

A sample page isn’t going to help much. You would also need all the dmx folders and proper bootstrap path. I would invest in one month of Wappler and test your exact needs.

Screen Shot 2021-12-23 at 10.19.26 AM

If you like you can go to https://www.lawryk.ca/ and save any page you like and try it out. It’s just my personal site done with Wappler. But as I say, without all the dmx folders and proper bootstrap path it’s not going to work.

I wouldn’t mind going pro for a month. Done so in the past.

But since there are no real tutorials on e.g. “how to build mysql crud with search, export, sorting, filter, edit, master + child rows, selectbox, multiselect, conditional field css…”, I am afraid I will end up being frustrated. Haven’t even seen a demo yet.

I do understand, that Wappler is flexible and not an ui library. But I will need some point to start, when I want to display and manipulate data from mysql using a wappler build.

I am looking for forms, crud table, charts and cards from mysql data for now and I would want to display such pages inside Joomla 4 CMS.

Can you point me to the documentation for building custom joomla modules that embed external pages? I think that is basically what you are looking for and it shouldn't be difficult.

You would still need to run your wappler website in some server given that you are going to embed.

Sure: a very simple joomla 4 module (that I have build myself).

URL: https://docs.joomla.org/J4.x:Creating_a_Simple_Module

The default.php will be called and I could output HTML/JS/PHP. Since all Wappler files would be located inside the module, why should an include not work?

I would need to check the user id of current logged in user.
The user id will be used to filter sql results per user.

use Joomla\CMS\Factory;
$user = Factory::getUser();

if (!$user->guest) 
{
 echo 'Logged in as<br />';
 echo 'User name: ' . $user->username . '<br />';
 echo 'Real name: ' . $user->name . '<br />';
 echo 'User ID : ' . $user->id . '<br />';
}

What information do you need to pass between your wappler website and joomla or viceversa?

Answer see above. Sorry! Must have edited my post instead of creating a new reply.

modules are located here: jooma4root/modules/mod_wappler
default.php located here: jooma4root/modules/mod_wappler/tmpl/default.php

The only limitation I can foresee is knowledge and if it’s not there it’s learnable.
You could go the iframe route being called inside an administrator module.
I would just be concerned how to approach this from a security perspective. You can share sessions in a new(wappler) database, implement a SSO between both sites when embedding or reuse the user and sessions table from joomla’s database. Wappler supports bcrypt which is used by joomla 4 to hash and verify the passwords.

When the output of my Joomla 4 module is e.g. a wappler page (inside the CMS), then I can use standard Joomla ACL in order to grant access to the wappler form, table or chart inside a joomla 4 page…or deny access.

I don’t really like iframes.
Or is there an easy way to have iframe height dynamic?

Best approach would be to echo what’s inside the index.html (wappler file) as a kind of widget.

I understand you.

You can find several solutions for this in stackoverflow.

Try echoing it :wink: It's a full php wappler project.

CMS packages like Joomla, WordPress and Drupal are best used on their own. Sure, you can use a text editor to create a theme. But that is about it.

What I am trying to say is, use Joomla or use Wappler, do not combine the two unless you want to create a theme using Wappler.

I am in the process of creating a CMS site using Wappler. Have a look at this playlist.

Yes, I hear you, this is a NodeJS version, which I would recommend. But this could just as easily be created using PHP and a MySQL database. In fact you could use your current database.

Try Wappler and you will soon realise that Joomla is for those that do not wish to further themselves as web developers.

1 Like