Thank you for your reply. I managed to get assistance with this issue from someone, who pointed out that I needed to right-click on the root "Content" node in the Umbraco content tree, and then choose "Republish".
After I did that, all of the images which were originally missing now appeared. So after manually running SQL scripts for the images, I need to manually "Republish" the content.
EDIT: Please ignore the above comment, it was meant for another question I had asked! Doh.
Right I've been away for a couple of days, so sorry for the delay.
This turned out to be a total DOH! moment. Turns out that the Umbraco client site that I'm working one does not display a login page by default (don't ask), so each time I was testing my code, I wasn't actualyl logged in - I did not know that, since it never asked me to log in!!! Argh.
I have to manually navigate to the login page, enter a username and passwed and hey presto all the Member API stuff now works. Humph.
How to get current member in a Razor macro.
Hi there.
I'm unable to get the current member inside a Razor macro.
I have tried the following methods:
Basically I need to get the current member in orde to do some processing using that member's ID.
Are the above the only ways of trying to get the current member, or is there an alternative?
Cheers.
Jas.
Hi Jason,
When using razor remember to add those and run a check to see if a member is well login.
You can also access member properties via standard ASP.NET provider model, so you can do this:
Hi Fuji.
Thank you for your reply. I managed to get assistance with this issue from someone, who pointed out that I needed to right-click on the root "Content" node in the Umbraco content tree, and then choose "Republish".
After I did that, all of the images which were originally missing now appeared. So after manually running SQL scripts for the images, I need to manually "Republish" the content.
EDIT: Please ignore the above comment, it was meant for another question I had asked! Doh.
If you use the Member API it does a lot of calls to the database. This example can help: http://our.umbraco.org/forum/developers/extending-umbraco/27626-Accessing-Member-Information?p=1#comment105493.
Jeroen
Hi guys.
Right I've been away for a couple of days, so sorry for the delay.
This turned out to be a total DOH! moment. Turns out that the Umbraco client site that I'm working one does not display a login page by default (don't ask), so each time I was testing my code, I wasn't actualyl logged in - I did not know that, since it never asked me to log in!!! Argh.
I have to manually navigate to the login page, enter a username and passwed and hey presto all the Member API stuff now works. Humph.
Thanks for all your efforts though guys.
Cheers.
Jas.
is working on a reply...