Recent

Author Topic: [Solved] Lazarus Website Mobile Friendly  (Read 4342 times)

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
[Solved] Lazarus Website Mobile Friendly
« on: August 23, 2020, 11:02:05 pm »
Hi, I've downloaded the sources

svn
https://svn.freepascal.org/svn/lazaruswebsite/trunk

And I've installed XAMPP for Windows, put the lazaruswebsite folder on the D:\xampp\htdocs\lazaruswebsite folder and nothing shows when accessing localhost. The XAMPP local sites are displayed fine.

I'm just wanting the website to open, to adapt the styles to be mobile friendly, don't need to touch the PHP code, but need it to preview the website.

Any workflow to run the website locally on Windows?
« Last Edit: November 15, 2020, 07:53:27 pm by lainz »

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6803
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus Website Mobile Friendly
« Reply #1 on: August 23, 2020, 11:35:39 pm »
Unfortunately not.
It is a long time since real work was done on the page.

I don't recall how I did it back then...

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
Re: Lazarus Website Mobile Friendly
« Reply #2 on: August 23, 2020, 11:43:17 pm »
Ok no problem I will figure it.

I've updated the OPM website to make it mobile friendly (fixed the width of the card elements) as well I've installed a new theme based on material design, to look a bit better.

Source:
https://github.com/lazarusccr/LazarusPackagesRepository

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
Re: Lazarus Website Mobile Friendly
« Reply #3 on: August 24, 2020, 12:17:12 am »
Unfortunately not.
It is a long time since real work was done on the page.

I don't recall how I did it back then...

Seems that I have a newer version of PHP installed, newer than the one Lazarus website uses. (Showed the PHP errors and get some deprecations in the config file, so the entire page is made for an older PHP). Which version of PHP is using the website?

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6803
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus Website Mobile Friendly
« Reply #4 on: August 24, 2020, 02:21:32 am »
I've mailed the server admin. Don't know how busy he his. I let you know once I have an answer.

GetMem

  • Hero Member
  • *****
  • Posts: 3806
Re: Lazarus Website Mobile Friendly
« Reply #5 on: August 24, 2020, 08:13:50 am »
Thank you @lainz(Leonardo) :),  I updated the webpage. Please test.

avra

  • Hero Member
  • *****
  • Posts: 2081
    • Additional info
Re: Lazarus Website Mobile Friendly
« Reply #6 on: August 24, 2020, 09:08:19 am »
I've installed XAMPP for Windows
Btw, you might be interested in this stack since it also integrates nodejs and firebird:
https://www.pilotlogic.com/sitejoom/index.php/projects/ultra-web-server.html
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

Bi0T1N

  • Jr. Member
  • **
  • Posts: 51
Re: Lazarus Website Mobile Friendly
« Reply #7 on: August 24, 2020, 11:48:58 am »
I've updated the OPM website to make it mobile friendly (fixed the width of the card elements) as well I've installed a new theme based on material design, to look a bit better.

Looks fine on desktop and mobile. Good work! :)
Just a small suggestion: maybe give the categories dropdown a proper name? If you browse the website for the first time its not clear what the * is for.
« Last Edit: August 25, 2020, 10:16:11 am by Bi0T1N »

Marc

  • Administrator
  • Hero Member
  • *
  • Posts: 2514
Re: Lazarus Website Mobile Friendly
« Reply #8 on: August 25, 2020, 09:11:19 am »
We're running PHP 5.6, since the website code doesn't work with PHP 7.
Since the sources are public I'm just waiting till there is an update.
Feel free to improve the PHP code
//--
{$I stdsig.inc}
//-I still can't read someones mind
//-Bugs reported here will be forgotten. Use the bug tracker

devEric69

  • Sr. Member
  • ****
  • Posts: 419
Re: Lazarus Website Mobile Friendly
« Reply #9 on: August 25, 2020, 10:04:40 am »
As @Avra already said, Uniserver (written in Typhon over Lazarus) is a very accomplished WAMP, and is very actively maintained (they offer versions from php 5.4 to 7.3, with different versions of MariaDB + phpMyAdmin, ...).
- beginning of explanation: https://wiki.freepascal.org/Projects_using_Lazarus_-_Web#Uniform_Server .
- example of support: http://forum.uniformserver.com/topic/3185-problems-with-the-connection-to-the-socket/ .

It comes in the form of self-extracting zip files (all compatibles for the same release number, of UniServer):
- a zip for the executable, that makes the facade between Apache, Php, mysql \ mariadb \ etc..
- several zips per version of MySQL \ maradb,
- several zips per version of Php (and PhpMyAdmin),
- several zips per version of Perl (and its adminer),
...\...
Just delete in a directory what already exists, and then unzip a new version of Php, for example, in it. Nothing is written in the registry. It's very clean  O:-) .

Currently, i'm using plugins such as ZeroXIII_uniservice_2_2_0.exe, ZeroXIII_mariadb_10_0_29.exe, ZeroXIII_phpmyadmin_4_4_15_10.exe (these are 7zip self-extracting files of the release XIII), to test Php 7.1 draft development.
« Last Edit: August 25, 2020, 10:24:40 am by devEric69 »
use: Linux 64 bits (Ubuntu 20.04 LTS).
Lazarus version: 2.0.4 (svn revision: 62502M) compiled with fpc 3.0.4 - fpDebug \ Dwarf3.

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
Re: Lazarus Website Mobile Friendly
« Reply #10 on: August 25, 2020, 04:28:13 pm »
We're running PHP 5.6, since the website code doesn't work with PHP 7.
Since the sources are public I'm just waiting till there is an update.
Feel free to improve the PHP code


Hi thanks, I will try improving the html for mobile.

I can install the bootstrap grid, not the components just the grid system? Is more easy to make it responsive without touching a lot of css.

Marc

  • Administrator
  • Hero Member
  • *
  • Posts: 2514
Re: Lazarus Website Mobile Friendly
« Reply #11 on: August 25, 2020, 05:20:41 pm »
Are you asking me ? I've no idea what "the bootstrap grid" is.
//--
{$I stdsig.inc}
//-I still can't read someones mind
//-Bugs reported here will be forgotten. Use the bug tracker

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6803
  • Debugger - SynEdit - and more
    • wiki
Re: Lazarus Website Mobile Friendly
« Reply #12 on: August 25, 2020, 05:37:53 pm »
Hi thanks, I will try improving the html for mobile.

I can install the bootstrap grid, not the components just the grid system? Is more easy to make it responsive without touching a lot of css.

You mean some css/js files from the bootstrap library?

So long as their license allows us to
- host the copy
- have the copy in our repro for the website
- They work on all current browsers

I would not see a problem.

I.e. for the main website, those files go into svn, and will then be uploaded, with all the other files.

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
Re: Lazarus Website Mobile Friendly
« Reply #13 on: August 25, 2020, 06:57:48 pm »
Hi thanks, I will try improving the html for mobile.

I can install the bootstrap grid, not the components just the grid system? Is more easy to make it responsive without touching a lot of css.

You mean some css/js files from the bootstrap library?

So long as their license allows us to
- host the copy
- have the copy in our repro for the website
- They work on all current browsers

I would not see a problem.

I.e. for the main website, those files go into svn, and will then be uploaded, with all the other files.

The license is MIT
https://github.com/twbs/bootstrap/blob/main/LICENSE

Ok so there is no problem.

lainz

  • Hero Member
  • *****
  • Posts: 3918
  • Leandro Diaz
Re: Lazarus Website Mobile Friendly
« Reply #14 on: August 26, 2020, 04:00:02 am »
Hi again, I've modified the website using bootstrap (finally I've used the full library to include the responsive mobile navbar and some other features).

I'm using the bootstrap grid system where it applies.

I've not touched the content or the style of the website, just did some minor modifications in the style file, and of course using bootstrap grid in the main html template, and also in the features page.

I've not touched PHP code.

Features:
- Now it works on mobile, has mobile navigation bar.

ToDo:
- Fix the footer, for some reason on mobile it is not displayed properly, a part is 'pink' and another part is 'gray'.

Link to download with my changes
https://github.com/lazarusccr/lazaruswebsite

I've used this software to test the website:
- xampp-windows-x64-5.6.40-1-VC11-installer.exe
- Latest Google Chrome
- Latest Edge Chromium
« Last Edit: August 26, 2020, 04:01:49 am by Leandro »

 

TinyPortal © 2005-2018