Open danimesq opened 6 years ago
I'm sure you know how to use ZeroFrame api, so here goes the code:
ZeroFrame.cmd("siteInfo", [], function(siteInfo) {
console.log("You are", siteInfo.cert_user_id); // e.g. gitcenter@zeroid.bit
console.log("Your ID is", siteInfo.auth_address);
By the way, you can probably find the anseers to your questions in my tutorials: https://github.com/krixano/ZeroNet-Dev-Center/issues/28
Thanks, it returns user's ID. It will be usefull on projects. But I'm asking for user's public Bitcoin address (identy) ^^
Unfortunately, that's not possible, as far as I know. :(
Well, @HelloZeroNet @shortcutme should introduce this feature on ZeroFrame, to site detects its user. It will be useful on ChameleonHub, where I'll show user's address, avatar and data limit.
@imachug
I left some issues on Kiwipedia's repo on GitHub. Maybe there are also issues I posted on Kiwi's and Git Center's repos on Git Center.
Yeah, I just don't really have much time to work on Kiwipedia, but I'll try to implement that when I have time.
@imachug I welcome if you want to move to ChameleonHub, since I'll be actively increasing user data limits.
I already added a good limit for @D14na.
I tried, but can't make ZeroMe switch to your hub -- do you know a solution?
@imachug Is this a bug on ChameleonHub or a misconfig?
I think it's not a bug, I'm just not sure how to correctly switch hubs on ZeroMe. It would be great if someone told me how to do this.
@DaniellMesquita If you wouldn't mind, could you give me a quick tl;dr breakdown of how Hubs work on ZeroNet. What's the difference between ZeroMe and ChameleonHub? It seems as though you share the same data? Is that correct? Thanks!
@d14na I don't know if it has been introduced in 2016 or 2017, but there is the merger sites feature. For scalability purposes, instead of ZeroMe loads all user posts/comments, those data are saved on individual hubs. Each hub stores its own users data: full name, bio, avatar, posts, comments. ZeroMe have merger permissions over its hubs, to read and write data. But read/write data in not-merged sites is possible using the CORS (cross-site requests, very claimed by me and @April93) plugin. But merged sites/hubs are more used, to be related to a site.
@imachug
I think it's not a bug, I'm just not sure how to correctly switch hubs on ZeroMe. It would be great if someone told me how to do this.
This tutorial is useful for this: http://127.0.0.1:43110/blog.kaffie.bit/?Post:25:How+to+change+your+ZeroMe+Hub
@DaniellMesquita ok, so everyone starts at ZeroMe, then it manages where it pulls the data from. If you're subscribed to multiple hubs, how do you know which one your data is being written to? Can you only choose one at a time? Also, if you could provide a link to any docs, that would be very much appreciated.
If you're subscribed to multiple hubs, how do you know which one your data is being written to? Can you only choose one at a time?
You are not subscribed to hubs, but you seeds they. And the data about user's choosen hub is written on ZeroMe's user registry (that is also a merged site of ZeroMe).
Also, if you could provide a link to any docs, that would be very much appreciated.
Not all things are documented on ZeroNet's docs, so I could not find it. But @imachug did great tutorials about ZeroNet, in The truth about ZeroNet's file.
But @imachug did great tutorials about ZeroNet, in The truth about ZeroNet's file.
@DaniellMesquita I'm stunned!! I can't believe this package exists and I'm only NOW seeing it. Haven't slept since I unpacked it. This would have saved me much, much hard-ache trying to understand the Zeronet internals.
Does this exist anywhere on the clearnet or the zeronet? Just sent ivanq a message on ZeroMail. I'd like permission to add this to my new portal http://127.0.0.1:43110/zerocoding.bit. This is a MUST READ for any developer interested in building on the Zeronet.
Its a holiday weekend in the US, and I plan to spend it integrating all this new knowledge into Zeronet Explorer.
I also have some tutorials on ZeroNet Dev Center.
@krixano I think you're talking about http://127.0.0.1:43110/DevCenter.bit. Just discovered this today. Its either my birthday or early Christmas, maybe both lol. Either way, its gonna be a fun holiday weekend.
Hey @d14na, I'm @gitcenter
on ZeroNet, I'm seldom checking @ivanq
. Can you resend your message to @gitcenter
please?
Can you resend your message to @GITCenter please?
@imachug its basically what I already posted here.
just wanted to know if your docs were accessible somewhere. it basically answers the 100 or so questions that I had pending (with examples) about how this whole thing works. i've read the docs several times, but i haven't been able to read the actual source, since its GPL and my app will be MIT. its been painful getting a technical understanding of the internals. now that you've explained it, I realize the db stuff would have taken FOREVERRRRR to figure out. i may be dreaming, but I now think I can get an MVP out for Zeronet Explorer by next week.
anyway, I'm very happy to mirror the docs @ http://127.0.0.1:43110/zerocoding.bit/the-truth-about-zeronet or at least link to wherever you have it now.
i also found http://127.0.0.1:43110/DevCenter.bit today, so i'm going through that now, before I get back to "happy" coding.
@HelloZeroNet @shortcutme