Jump to content

Guldstrand

Members
  • Posts

    64
  • Joined

  • Last visited

About Guldstrand

  • Birthday 06/11/1977

Profile Information

  • Gender
    Male
  • Location
    Orebro, Sweden

Guldstrand's Achievements

Member

Member (2/5)

0

Reputation

  1. Can any kind person help with a sample code for the following scenario: I need to search/retrieve price from one (or several external pages) and display the lowest price BEFORE adding the same product to our non-profit webshop. Thanks in avance! 🌹
  2. Can someone please, please help me to fix my issue with enabling SSL. I installed Azuracast (radiopanel) for almost 1 year ago, and all worked great. I'm not sure whats happend the last month, cause i have issues with creating new SSL-certs. Azuracast is installed on an own server, (behind port 8443). I have a separate server from before which already uses ports 80 and 443 for websites etc. Therefore I am forced to use a custom port for Azuracast. Again, everything worked fine from the start, don't ask me how. But now the radio stream does not work, due to no SSL certificate. I get the following error when I try to create a new certificate in the Azuracast panel: Challenge validation failed: IP HERE: Invalid response from https://MY-DOMAIN/.well-known/acme-challenge/xYQP7DEJ-85ao70juwq7jtAXjXUE4e0dMZRhFltBuSE: 404 (urn:ietf:params:acme:error:unauthorized) at /var/azuracast/www/vendor/skoerfgen/acmecert/src/ACMEv2.php:145)"}
  3. Sorry, but I don't really understand what you mean by this? I just want an solution that rewrites a variable (slug) directly to domain.com/$variable/, without this breaking any of the other rules that exist. I know that this possibility should exist, because it can be done in e.g. Wordpress. But the ways I've tried in the past, to achieve this, have always broken the other rules.
  4. Yes, I know how it works. It may be me explaining it a bit clumsily. As I said, I already have rules that sends: domain.com/article.php?id/slug=$variable --> domain.com/articles/$variable/ domain.com/event.php?id/slug=$variable --> domain.com/events/$variable/ ...and so on, and that works without any issues. But now I need a solution where I can put all the subpages (which are created dynamically and fetched from mysql) directly under domain.com/subpage/. I know that it should be possible to do this, because among other things Wordpress has this possibility. And I don't know what I have done now, because now you are not sent to a 404 page when an address does not exist. (Been sitting with this for so long now, and may have gone blind.) You can just keep adding characters to the link, and you stay on the same page, and are not forwarded to the 404 page, which worked earlier. 😩 I'm attaching my htaccess file, and I'd be super grateful for any help improving/optimizing it. htaccess.txt
  5. Thanks, but no, that's not how I want it. That way works well for articles, events, posts, etc. I need a rewrite rule that redirects all dynamic pages to to domain.com/slugname/.
  6. I need to rewrite urls from page.php?slug=name to domain.com/name/, but every try is breaking all other rules in my htaccess-file. Here is a bit from my htaccess-file: Options +FollowSymLinks -MultiViews RewriteEngine On RewriteCond %{REQUEST_URI} !(/$|\.) RewriteRule (.*) %{REQUEST_URI}/ [R=301] ErrorDocument 404 /404.php RewriteCond %{HTTP_HOST} ^domain.com$ RewriteRule ^(.*)$ https://www.domain.com/$1 [R=301,L] RewriteRule ^contact/ contact.php [L,QSA] .... RewriteRule ^news/([0-9]+)/(.*)/ view-article.php?id=$1&title=$2 [L,QSA] RewriteRule ^(.*)/ page.php?slug=$1 [L,QSA] I'm still trying to learn, and would appreciate any help solving this, and also optimizing the other rules, if needed?
  7. Can someone please help me with the following error: Uncaught mysqli_sql_exception: Incorrect string value: '\xE3\x12N\x1C\xE3\xA0...' for column `trptreg`.`users`.`secret` I've searched and tried everything, but i still get the above error when i try to save a hash in MySQL. Here is the column "secret": secret varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL
  8. I fetch a "page" (content) dynamically from mysql, which is then displayed at domain.com/page.php?slug=pagename. There are several other rewrite rules that work, such as domain.com/news/$id/$title/. This is the only one that doesn't work as it is right after the domain? (domain.com/$pagename/) Again, all other rules are working: RewriteRule ^news/([0-9]+)/(.*)/ news-article.php?id=$1&title=$2 [L,QSA]
  9. Options +FollowSymLinks -MultiViews RewriteEngine On ErrorDocument 404 /404.php RewriteCond %{HTTP_HOST} ^domain.com$ RewriteRule ^(.*)$ https://www.domain.com/$1 [R=301,L] RewriteRule ^(.*)/ page.php?slug=$1 [L,QSA] I have some kind of a "conflict" with the code above in my htaccess-file. When i add the rule to have all page.php?slug=$pagename to domain.com/$pagename, the other rewritten page URLs breaks. I'm not completely familiar with mod_rewrite yet, but I'm trying to understand. I would be extremely grateful if someone could help me with this. Thanks in advance..
  10. I have a question about how to solve it with a database I am working on. The idea is to have different types of optical media, and I'm thinking a bit about how to solve it with the categories. There will be two different levels in the categories, but the question is whether I should include the formats under, for example, the game category. Having "ps4, ps5, wii" together with the game types / genre "platform games, action games" etc.? (Same for movies that have the formats "vhs, dvd, blu-ray".) Or is it better to have all the "formats" in a separate table? And when is it really a "category" or a "type / format" thing? I am grateful for all the feedback and suggestions.
  11. What is the best way to store a few formats/types on different mass media? Like "vhs", "dvd", "blu-ray" for movies or "lp", "cassette", "cd" etc for music. Is it ok with an ENUM field with all types / formats or should I have a separate table just for these? (I already have a table with all genres.)
  12. How can i show/list all categories with subcategories in a good way? PARENT1 --child1 --child2 PARENT2 --child1 --child2 I have the following columns: `catID` int(10) UNSIGNED NOT NULL, `catPARENT` int(10) UNSIGNED NOT NULL, `catNAME` varchar(50) NOT NULL, `catICON` varchar(50) NOT NULL, `catTEXT` text NOT NULL
  13. Thanks for your reply. I can't use UNION cause the tables or different, as i wrote in my first post.
  14. How can I do a keyword search in two completely different tables? In one table you search for "movie title" and in the other table "actor name".
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.