Sorry for late reply, this should be fixed,
or rather i created some input validation that removes illegal characters from the link before saving
Sorry for late reply, this should be fixed,
or rather i created some input validation that removes illegal characters from the link before saving
No worries, I forked your github repository and made my own changes to allow special characters
elseif (isset($_REQUEST['id'])
&& preg_match('/^([a-zA-Z0-9-_]+)$/', $_REQUEST['id']))
See no problem with allowing dashes and underscores, If you’d like you can do a pull request for your changes. Just make sure to add the characters to the new front end validation as well.
Great add-on!! Just what I needed.
Thank you for your work!!
I’ve tried to create a style.css
file in folder share\limited-guest-access
with this content, but the web page with the buttons does not change its style at all.
I don’t know what I’m making bad.
I’m sorry the instructions are probabaly a bit unclear:
place the injection file files in the root of the addon data folder, for me this translates to:
[path/to/hassio]/addons/data/224ec5dd_limited_guest_access/
In that folder you should see an options.json
file already
It’s strange. I cannot locate that folder. In fact, addons folder is empty. I’ve tried to locate the folder where this addon is installed without success.
I’ve tried to create the folder
/root/addons/data/224ec5dd-limited-guest-access
which is the Hostname
I can see in the addon main page in HA, and put there the style.css, but nothing has changed, as expected.
I really don’t know where limited_guest_access is been installed. I’ve looked for it in:
/root/config/custom_components
/root/config/www/community
but nothing related.
I’ve never used Home Assistant OS (which i think you may use), but i think you may be within your home-assistant container, not on the host system
What we want to do is to place the file in the /data folder within the addon container,
which in turn is mounted from the host
in my supervised docker installation i can find these files in this folder:
/usr/share/hassio/addons/data/224ec5dd_limited_guest_access
In other words, this:
ls /usr/share/hassio/addons/data/224ec5dd_limited_guest_access/
links/ options.json style.css
is the same folder as:
bash -c 'docker exec -it $(docker ps|grep limited_guest_access|awk \'{print $1}\') bash -c \'ls /data\''
links options.json style.css
I’m actually not sure how to get access to those files on a HA OS system
So, in practical terms, I think it’s not practical/feasable for an user to access data folder of the addon.
In any case, the addon is great!
I don’t know (I really don’t know anything about containers) if it would be feasable to make a feature request to mount the data folder in a place readable from Home Assistant OS. I suppose not, if you haven’t used it.
Another good future feature would be to get a log of actions executed in the web UI.
In the log of the addon I cannot see that, at least in a readable way.
I appreciate your feature requests! if it’s not too much of a trouble create issues in the github.
I suppose i could add css-styling to the “configuration” part of the addon as an alternative to adding it as files;
I’m not sure if i redirected the accesslog to the log portion of the addon or not, but that would be doable i think!
Sure! Now I know they are doable, I’ll write them in GitHub tomorrow.
Thank you very much!
I’ve been able to access docker and style.css, but I’ve tried a simple style.css in /data:
<style type="text/css">
body {
background-color: powderblue;
}
h1 {
color: blue;
}
p {
color: red;
}
</style>
but the links page does not change at all. I’ve tried to restart the addon but in any case nothing changes.
I’m missing anything?
Sounds like you are making good progress, I tried adding your style.css into my instance, and this was the result:
Try this command to get into the correct container
docker exec -it $(docker ps | grep limited_guest_access | awk '{print $1}') bash
It does not need to be restarted after adding style
Maybe I’m not putting style.css in correct place. This is what I have:
That’s strange, I think everything looks as it should
Maybe try opening the developer tools and check the box for “disable cache” in the network tab, and then reload the page.
I’m a bit confused: I don’t have a network tab in developer tools… Maybe it’s because I’m on home assistant OS.
I ment the developer tools in the browser, not in home assistant
Just to rule out that that the issue is that the browser has cached the tool
I’ve tried in different browsers and in a PC and mobile phone, and in all of them I see the web page in black, ignoring style.css.
In any case, if this is not a general problem, never mind, as the important thing is that the add-on works great as it does.
so what a perfect addon for those of us with Vacation rentals as well. Is there a method that I can use with some appdaemon automation (figured I’d need the full power of the python) to where I can create a link via a api call or something to the like? I’d like to be able to have it auto generate the link and set the start/end date/time and I can use the reservationID for the custom link to have it automagically work and then all I need to do is just go in here and send my guests the link that it creates. If not no biggie I can just manually do it