Search found 141 matches

by Julcar
Jan 05, 2023 9:41
Forum: Libraries Questions
Topic: FreeBasic/SQL
Replies: 5
Views: 5270

Re: FreeBasic/SQL

Maybe you could try my own sqlite implementation: sqlite3.bi data.bi data.bas you should include only data.bi anywhere you need to perform sql queries, here is a dummy example: #include "data.bi" Dim myDST as DataSet, sql as string OpenConnection("data.s3db") sql = "SELECT *...
by Julcar
Jul 23, 2022 9:51
Forum: General
Topic: How could I imitate VBScript Array() function?
Replies: 10
Views: 13042

Re: How could I imitate VBScript Array() function?

Instead of using wrapper macros (which aren't even possible for functions), here's a generic implementation of an Array macro for strings specifically: Type StrArrayType contents(any) as string End Type Function hStrArray(count as integer, ...) as StrArrayType dim ret as StrArrayType redim ret.cont...
by Julcar
Jul 15, 2022 20:51
Forum: General
Topic: How could I imitate VBScript Array() function?
Replies: 10
Views: 13042

How could I imitate VBScript Array() function?

In VBScript there is an Array() function: https://www.w3schools.com/asp/func_array.asp In FB is possible to do this: DIM AS STRING MyDogs(2) = {"spike", "bitter", "bobby"} Now let's say I have the following procedure SUB FindMyDogs(MyDogs() AS STRING) FOR i AS ULONG = 0...
by Julcar
Jan 24, 2022 20:28
Forum: General
Topic: Which kind of parametrized sql queries do you preffer?
Replies: 5
Views: 704

Re: Which kind of parametrized sql queries do you preffer?

This is data.bi http://chiselapp.com/user/julcar/repository/IguanaCMS/artifact/38675a249ae231ba Here is data.bas http://chiselapp.com/user/julcar/repository/IguanaCMS/artifact/9b75be4337e039fb In data.bas are the internal and external functions to manage data with sqlite (can be modified for other r...
by Julcar
Jan 24, 2022 20:22
Forum: General
Topic: Which kind of parametrized sql queries do you preffer?
Replies: 5
Views: 704

Re: Which kind of parametrized sql queries do you preffer?

Yes, I decided too to named parameters because parameter reusing feature, lets say I need to query the same user_id in two relational queries, I can use a unique @user_id param and place it 1 or more times.
by Julcar
Jan 24, 2022 15:51
Forum: General
Topic: Which kind of parametrized sql queries do you preffer?
Replies: 5
Views: 704

Re: Which kind of parametrized sql queries do you preffer?

How about: query = "SELECT {1} FROM {2} WHERE id = {3}" buildQuery( query, "username", "users", userID ) Not trivial, but certainly doable. Something like this is used in the AspBB project, to be honest it was one of the my options at the beggining, but I preffer to lo...
by Julcar
Jan 24, 2022 6:48
Forum: General
Topic: Which kind of parametrized sql queries do you preffer?
Replies: 5
Views: 704

Which kind of parametrized sql queries do you preffer?

Hello guys, this topic is a sort of poll to help me to decide which kind of parametrized sql queries do you preffer as programmer. I'm writting a sql command builder inspired in ADO component of Microsft, it has 2 types of parametrized queries: 1: unnamed parameters and replacement by ordering sql =...
by Julcar
Jan 15, 2022 9:49
Forum: Community Discussion
Topic: What are you using FB for and what features do you use most?
Replies: 62
Views: 8125

Re: What are you using FB for and what features do you use most?

Let me tell my history with FB: I started out to learning web programming circa 2005, and the first tutorial I found was about classic ASP with VB Script. Then I learned PHP, tried to do things but I didn't feel good with PHP (I was sort of a disaster with C syntax), so I choosed to continue with VB...
by Julcar
Jan 07, 2022 7:05
Forum: Community Discussion
Topic: What are you using FB for and what features do you use most?
Replies: 62
Views: 8125

Re: What are you using FB for and what features do you use most?

Since I meet FreeBasic (2010) and learned in deep the language (2013) I've used it mainly for web development. My biggest project is IguanaCMS, a web page engine written from the very scratch in 100% freebasic, zero external dependencies aside those provided by the OS (I use some winapi calls) I've ...
by Julcar
Jan 06, 2022 7:41
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Yes, the linux compiler script is a bit outdated and needs to be fixed, what I need is some more spare time xD This shouldn't be the build script. I think it's the code itself is not tested on Linux and to some extern being Windows only. I'm not sure, though. The missing functions are implemented b...
by Julcar
Jan 05, 2022 17:36
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Yes, the linux compiler script is a bit outdated and needs to be fixed, what I need is some more spare time xD
by Julcar
Jan 05, 2022 9:01
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Also, be prepared to find bugs regarding parameters in url leading to nowhere, to be honest almost 100% of my tests are with fancy urls activated, so now I am giving some time to fix these bugs, so stay tuned with my repo timeline.
by Julcar
Jan 05, 2022 8:17
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Finally I saw User Login. Thank you very much. I will start experimenting with it. I've just noticed something: Tinyweb also has a bug, a Set-Cookie header cannot co-exists with a Location Header, and that's just the way I manage users login, so, in order to bypass this you have to comment lines 18...
by Julcar
Jan 05, 2022 7:32
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Please paste your sitelist.json here Here you are: { "default_site" : { "default_base_path" : "C:\\other\\download" } } you have missing the final backslash, it should be: { "default_site" : { "default_base_path" : "C:\\other\\download\\" ...
by Julcar
Jan 04, 2022 22:49
Forum: Projects
Topic: IguanaCMS - The first ever CMS written in FreeBasic
Replies: 61
Views: 10479

Re: IguanaCMS - The first ever CMS written in FreeBasic

Going to http://127.0.0.1/users/register.html I only saw 403 Forbidden. I followed your instructions so I have sitelist.json next to index.exe and it already points to the correct location. Change in data/settings.json the property site_fancy_url from true to false, as tinyweb does not support url ...