Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0
This is the forum to discuss the Wrox book ASP.NET 2.0 Website Programming: Problem - Design - Solution by Marco Bellinaso; ISBN: 9780764584640
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #21 (permalink)  
Old March 26th, 2007, 09:36 AM
Friend of Wrox
 
Join Date: Mar 2007
Location: Creetown, UK
Posts: 488
Thanks: 2
Thanked 11 Times in 10 Posts
Default

Quote:
quote:Originally posted by 99mary
 When viewing the page ShowThread.aspx is changed number of the users in network - time their last activity, possible somehow this avoid, so in network from users only I?

Mary,

Are you referring to the admin funtion when looking at users?? I know that if i change an entry (as admin) for another poster, then it shows as that user having been active at the time as well. i think this is due to roles.impersonation. i'm not sure how you bypass this (if this is what you want), without breaking the security model.

jim

btw - i presume you got the other bits working okay?? i'm currently working on an implementation for the Priority flag i.e Announcement, Sticky, Normal etc... it's nearly there and i have a version running on www.jamestollan.com . i'll post the updated zip file when i've tested it properly.

  #22 (permalink)  
Old March 26th, 2007, 04:41 PM
plb plb is offline
Authorized User
 
Join Date: Jan 2007
Location: Oakland, CA, USA.
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Jim -
I see that you too have revised the look of the forum so as to differentiate it from the UI presentation of the Articles. I will study your implimentation. I like your new ShowForums page better than my own. Does your forum have new functionality yet? You wanted to add Stickies I think.

You should work on the About section soon. I'd like to see who you are.

Pat



http://weboperahouse.com
  #23 (permalink)  
Old March 26th, 2007, 04:42 PM
plb plb is offline
Authorized User
 
Join Date: Jan 2007
Location: Oakland, CA, USA.
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am continuing to rework the stock forum cosmetically. Today I revised the ShowThreads page. I reworked the Literal that shows the Forum Threads so that it mirrors the style of the site Bread Crumbs. I also changed the layout of the identity block to make it smaller and more compact.

I have made up a set of custom buttons for posting, locking, and quoting but these are a little hard to just substitute. It takes some coding to make image button equivalents.

Its starting to look like a real forum. A couple more days of formatting and then I will add some new functions. Then I think I can use this nice little forum in the new site I'm going to try to build next week.

Pat


http://weboperahouse.com
  #24 (permalink)  
Old March 27th, 2007, 02:21 AM
Friend of Wrox
 
Join Date: Mar 2007
Location: Creetown, UK
Posts: 488
Thanks: 2
Thanked 11 Times in 10 Posts
Default

Quote:
quote:Originally posted by plb
 I am continuing to rework the stock forum cosmetically. Today I revised the ShowThreads page. I reworked the Literal that shows the Forum Threads so that it mirrors the style of the site Bread Crumbs. I also changed the layout of the identity block to make it smaller and more compact.

I have made up a set of custom buttons for posting, locking, and quoting but these are a little hard to just substitute. It takes some coding to make image button equivalents.

Its starting to look like a real forum. A couple more days of formatting and then I will add some new functions. Then I think I can use this nice little forum in the new site I'm going to try to build next week.

Pat


http://weboperahouse.com
hi pat,

i've now completed my Priority functionality and tested it out thoughroughly. all works great and now my stickies/announcemnts are working great. i'll include it in an updated zip with everything i've done to date. should make for a nice leap in useability and funtionality.

once i'm out of this little loop and before leaving forum/posts for a bit, i'm going to create a couple of little webparts to display most active poster etc, etc... bascially, dashboard info to give a quick overview on the user's'homepage'

anyway

jim
  #25 (permalink)  
Old March 27th, 2007, 06:48 AM
Friend of Wrox
 
Join Date: Mar 2007
Location: Creetown, UK
Posts: 488
Thanks: 2
Thanked 11 Times in 10 Posts
Default

OK,

Finally, the latest version of this forums/posts thing. this release includes both the new layout for the Forum listing as per previous messages, toghether with the much vaunted Priority flag for top level posts (can only be applied by admin/editors of course!!).

ok, grab yourself the code here:

http://www.originaltalent.com/downlo...UpdateV1.3.zip

Good luck, jim

see it all in action at:

http://www.originaltalent.com/Default.aspx

[edit] updated broken link 22-may-2008
  #26 (permalink)  
Old March 27th, 2007, 08:26 AM
Authorized User
 
Join Date: Mar 2007
Location: , , .
Posts: 18
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have in view of if usual user views the page ShowThread.aspx, that amount of the users in network on page ManageUsers.aspx increases, profiles of the users herewith do not change beside user of no rights. I simply wanted to do how much users in network.

  #27 (permalink)  
Old March 27th, 2007, 04:44 PM
plb plb is offline
Authorized User
 
Join Date: Jan 2007
Location: Oakland, CA, USA.
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have started upgrading the look of my ShowForums page on the model Jim's Forum:
http://www.jamestollan.com/ShowForums.aspx

I'm not through but I've done a few little upgrades to include Topics, Posts, and Last Post columns. Right now these are simple Bound Columns. Later I will template them and add other values, links and multiple lines.

What is remarkable about these added features is that there was essentially NO PROGRAMMING much less any looping. I'm too simple minded to create a complex solution so I did it is a very simple fashion.

I just dropped the forums table on the form and auto generated a SqlDataSource control. I then created three super simple Views. One each for Threads, Posts, and Last Post Date. I created them graphically in SQL Server (I teach students how to write SQL in Query Analyzer but I seldom do so myself). They are:

vw_Forum_NumPosts
Code:
SELECT 
   ForumID, 
   COUNT(PostID) AS NumPosts
FROM 
   dbo.tbh_Posts
GROUP BY 
   ForumID


vw_Forum_NumThreads
Code:
SELECT 
   ForumID, 
   COUNT(PostID) AS NumThreads
FROM 
   dbo.tbh_Posts
GROUP BY 
   ForumID, 
   ParentPostID
HAVING
   (ParentPostID = 0)



vw_Forum_LastForumPost
Code:
SELECT     
   ForumID, 
   MAX(LastPostDate) AS LastForumPostDate
FROM         
   dbo.tbh_Posts
GROUP BY 
   ForumID


Then I made one more View called vw_Forums that simply joined these three views to the Forums table (graphically). The effect of which is to add three new columns to the Forums table. Lastly I replaced the table Forums with the view Forums in the SELECT statemnt in the SqlDataSource.

I know I should have probably done this in the DAL. Some would object that I should do this sort of thing completely in code not in the database at all. But I hate to type (and/or think) and its so easy in SQL.

Pat

http://weboperahouse.com
  #28 (permalink)  
Old March 27th, 2007, 05:19 PM
Friend of Wrox
 
Join Date: Mar 2007
Location: Creetown, UK
Posts: 488
Thanks: 2
Thanked 11 Times in 10 Posts
Default

Pat,

you naughty boy, ignoring the DAL :). I went down to the levels that marco did purely as an excercise to 'learn' asp.net (i come from a vb6/php/c background and had had very little asp.net experience until 4-5 weeks ago). i do agree that it involves a lot more typing (i might even create an addin to automate new classes once i've figured it all out, to save all the repetition [of sorts] across the various layers), however, i think the advantage being that as you scale up, then you have a logical heirarchy to follow that is consistant throughout.

of course, once i've been doing this asp.net malarkie for a few more months, i might be tempted to take the shortest/quickest path to achieve the end result.

i do feel that you may be missing out on an opportunity with the above approach insofar as the BizObject caching. i might be wrong in my assumption, but if you're linking the sql directly to your SqlDataSource, then you'll be querying the database with every hit on the page. using the full abstraction across the layers gives you the benefit of all the cacheing and reduced database activity. just something you should be aware of if you're going to be generating volume users. i feel that it's crucial to keep that kind of info in ones mind with every enhancement, especially ones that step outside the model.

i hope this doesn't come across as preachie in any way, i'm really just trying to explain the reasons why i'll probably continue with the longhanded approach with any enhancements that i undertake - of course, i might never deliver doing it that way :D

all the best for now - looking fwd to seeing your finished version soon

jimi

  #29 (permalink)  
Old March 27th, 2007, 06:09 PM
plb plb is offline
Authorized User
 
Join Date: Jan 2007
Location: Oakland, CA, USA.
Posts: 94
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I'm not really skipping the DAL in the long run. I'm just prototyping now. I'll redo it later. All my new video stuff has a DAL - but not a BLL. I have an architectural mish mash. But I'm not trying to sell a book.

At the present I have so few visitors caching hardly seems to matter. I have a few people wander through but no one uses the wizard or submits an article. I want to generate some traffic with what appears to be a conventional forum. That's why I've been so concerned about appearances. Forum afficionatos want something that looks like the other forums they habituate.

As for the classes and the DAL CRUD code. I intended to use Olymers but the MS LINC approach seems to be coming soon so I may just wait and continue to write my DAL classes by hand (actually cut, paste, search, replace).

I'm trying to understand Marco's approach better but in the meantime I wanted to get something up and running. I use my site as a demo when I apply for teaching or consulting jobs. I don't tell anyone that I cut some corners.

BTW the Forum joins have to be LEFT OUTER JOINs or else the new forum records will not show in the forum.

Pat

http://weboperahouse.com
  #30 (permalink)  
Old March 31st, 2007, 03:46 AM
Authorized User
 
Join Date: Mar 2007
Location: , , .
Posts: 18
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Good work jimi.
The Forum now simply excellent!
There was quite well add else voting, as well as searching for on forum.
But anyone have done the choice Avatars (in existing versions this uncomfortably). Necessary to provide possibility of the loading on server and choice with server already.

 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
AJAX Extensions ilegend .NET Framework 3.5 1 September 19th, 2008 03:32 AM
Some Extensions plb BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 2 July 29th, 2008 11:57 AM
PHP Extensions Dnigma Pro PHP 0 June 22nd, 2006 12:41 AM
File Extensions nbnelson C# 2 August 25th, 2003 12:09 PM
converting Forum.aspx to Forum.ascx (help) drfunkie BOOK: ASP.NET Website Programming Problem-Design-Solution 1 July 11th, 2003 12:27 PM



All times are GMT -4. The time now is 10:09 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.